File tree 1 file changed +11
-0
lines changed
hystrix-core/src/main/java/com/netflix/hystrix
1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -1306,6 +1306,17 @@ private R executeCommand() {
1306
1306
logger .warn ("Error calling ExecutionHook.onRunError" , hookException );
1307
1307
}
1308
1308
1309
+ try {
1310
+ Exception decorated = executionHook .onError (this , FailureType .BAD_REQUEST_EXCEPTION , e );
1311
+ if (decorated instanceof HystrixBadRequestException ) {
1312
+ e = (HystrixBadRequestException ) decorated ;
1313
+ } else {
1314
+ logger .warn ("ExecutionHook.onError returned an exception that was not an instance of HystrixBadRequestException so will be ignored." , decorated );
1315
+ }
1316
+ } catch (Exception hookException ) {
1317
+ logger .warn ("Error calling ExecutionHook.onError" , hookException );
1318
+ }
1319
+
1309
1320
/*
1310
1321
* HystrixBadRequestException is treated differently and allowed to propagate without any stats tracking or fallback logic
1311
1322
*/
You can’t perform that action at this time.
0 commit comments