Kaliappan
Kaliappan

Reputation: 660

Hystrix method deprecated

I am using hystrix api version 1.5.4. I am seeing that the method withExecutionIsolationThreadTimeoutInMilliseconds is deprecated. What is the alternate method instead?

    public HystrixHelloCommand(String message) {
    super(HystrixCommand.Setter.withGroupKey(HystrixCommandGroupKey.Factory.asKey("MyGroup")).andCommandPropertiesDefaults(
     HystrixCommandProperties.Setter()
    .withCircuitBreakerEnabled(true).withExecutionIsolationThreadTimeoutInMilliseconds(2000)));
}

Upvotes: 3

Views: 855

Answers (1)

Grinish Nepal
Grinish Nepal

Reputation: 3075

As per the Doc it is replaced by withExecutionTimeoutInMilliseconds and this is what it says:

com.netflix.hystrix.HystrixCommandProperties.Setter.withExecutionIsolationThreadTimeoutInMilliseconds(int) As of 1.4.0, replaced with HystrixCommandProperties.Setter.withExecutionTimeoutInMilliseconds(int). Timeouts are no longer applied only to thread-isolated commands, so a thread-specific name is misleading

Upvotes: 4

Related Questions