Class<? extends HystrixFallback> fallbackClass;
try {
fallbackClass = (Class<? extends HystrixFallback>) Class.forName(fallbackClassName);
} catch (ClassNotFoundException e) {
throw new CircuitBreakerException(e.getMessage(), e);
}
try {
fallbackClass.getDeclaredConstructor().setAccessible(true);
return fallbackClass.getDeclaredConstructor().newInstance();
} catch (Exception e) {
throw new CircuitBreakerException(e.getMessage(), e);
}
}