2

同時テストが失敗し、ログには次のように表示されます。

com.netflix.hystrix.exception.HystrixRuntimeException: community-serviceRibbonCommand は実行用のセマフォを取得できず、フォールバックも利用できません。

ソースコードを読みました。executionIsolationSemaphoreMaxConcurrentRequests で制御されているようです。

私の質問は、executionIsolationSemaphoreMaxConcurrentRequests を増やす方法ですか?

4

2 に答える 2

1

セッターを使用している場合は、次のことができます

    public class HystrixCommandInstance extends HystrixCommand<>        
      public HystrixCommandInstance() {
          super(Setter.withGroupKey(HystrixCommandGroupKey.Factory.asKey("SomeGroupName"))
          .andCommandPropertiesDefaults(HystrixCommandProperties.Setter()
                 .withExecutionIsolationSemaphoreMaxConcurrentRequests(200)));
      }
   }
于 2016-07-07T01:01:53.517 に答える