Minor changes after review
This commit is contained in:
parent
f2f2b48782
commit
fa68a02d60
|
@ -21,7 +21,7 @@
|
||||||
<java.version>1.8</java.version>
|
<java.version>1.8</java.version>
|
||||||
|
|
||||||
<!-- Hystrix -->
|
<!-- Hystrix -->
|
||||||
<hystrix-core.version>1.4.10</hystrix-core.version>
|
<hystrix-core.version>1.5.4</hystrix-core.version>
|
||||||
<rxjava-core.version>0.20.7</rxjava-core.version>
|
<rxjava-core.version>0.20.7</rxjava-core.version>
|
||||||
|
|
||||||
<!-- Testing -->
|
<!-- Testing -->
|
||||||
|
|
|
@ -1,16 +1,15 @@
|
||||||
package com.baeldung.hystrix;
|
package com.baeldung.hystrix;
|
||||||
|
|
||||||
import com.netflix.hystrix.*;
|
import com.netflix.hystrix.HystrixCommand;
|
||||||
import com.netflix.hystrix.collapser.RequestCollapserFactory;
|
import com.netflix.hystrix.HystrixCommandGroupKey;
|
||||||
|
import com.netflix.hystrix.HystrixCommandProperties;
|
||||||
|
import com.netflix.hystrix.HystrixThreadPoolProperties;
|
||||||
import com.netflix.hystrix.exception.HystrixRuntimeException;
|
import com.netflix.hystrix.exception.HystrixRuntimeException;
|
||||||
import org.junit.After;
|
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.Rule;
|
import org.junit.Rule;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.junit.rules.ExpectedException;
|
import org.junit.rules.ExpectedException;
|
||||||
|
|
||||||
import java.util.concurrent.ExecutionException;
|
|
||||||
|
|
||||||
import static org.hamcrest.MatcherAssert.assertThat;
|
import static org.hamcrest.MatcherAssert.assertThat;
|
||||||
import static org.hamcrest.Matchers.equalTo;
|
import static org.hamcrest.Matchers.equalTo;
|
||||||
|
|
||||||
|
@ -48,7 +47,7 @@ public class HystrixTimeoutTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenServiceTimeoutEqualTo5000_andExecutionTimeoutEqualTo10000_thenReturnSuccess()
|
public void givenServiceTimeoutEqualTo500_andExecutionTimeoutEqualTo10000_thenReturnSuccess()
|
||||||
throws InterruptedException {
|
throws InterruptedException {
|
||||||
commandProperties.withExecutionTimeoutInMilliseconds(10_000);
|
commandProperties.withExecutionTimeoutInMilliseconds(10_000);
|
||||||
config.andCommandPropertiesDefaults(commandProperties);
|
config.andCommandPropertiesDefaults(commandProperties);
|
||||||
|
|
Loading…
Reference in New Issue