diff options
author | Jon Marius Venstad <venstad@gmail.com> | 2021-10-21 13:58:55 +0200 |
---|---|---|
committer | Jon Marius Venstad <venstad@gmail.com> | 2021-10-21 13:58:55 +0200 |
commit | 28e3d42feebc04bc5385ab854ce6744d2a03b5e1 (patch) | |
tree | a97b9bc490873194afea3ed9d19c00b1d5a64c4c /vespaclient-container-plugin/src/test/java/com | |
parent | 2f39f64ddba3dfe6f0b9dd92d6284f4770003053 (diff) |
Use the default threadpool executor, with minimal blocking
Diffstat (limited to 'vespaclient-container-plugin/src/test/java/com')
-rw-r--r-- | vespaclient-container-plugin/src/test/java/com/yahoo/document/restapi/resource/DocumentV1ApiTest.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/vespaclient-container-plugin/src/test/java/com/yahoo/document/restapi/resource/DocumentV1ApiTest.java b/vespaclient-container-plugin/src/test/java/com/yahoo/document/restapi/resource/DocumentV1ApiTest.java index 51f43e521b9..9234f1cfa6f 100644 --- a/vespaclient-container-plugin/src/test/java/com/yahoo/document/restapi/resource/DocumentV1ApiTest.java +++ b/vespaclient-container-plugin/src/test/java/com/yahoo/document/restapi/resource/DocumentV1ApiTest.java @@ -136,7 +136,8 @@ public class DocumentV1ApiTest { access = new MockDocumentAccess(docConfig); metric = new NullMetric(); metrics = new MetricReceiver.MockReceiver(); - handler = new DocumentV1ApiHandler(clock, Duration.ofMillis(1), metric, metrics, access, docConfig, executorConfig, clusterConfig, bucketConfig, 1); + handler = new DocumentV1ApiHandler(clock, Duration.ofMillis(1), metric, metrics, access, docConfig, + executorConfig, clusterConfig, bucketConfig, Executors.newFixedThreadPool(2)); } @After @@ -752,7 +753,8 @@ public class DocumentV1ApiTest { @Test public void testThroughput() throws InterruptedException { DocumentOperationExecutorConfig executorConfig = new DocumentOperationExecutorConfig.Builder().build(); - handler = new DocumentV1ApiHandler(clock, Duration.ofMillis(1), metric, metrics, access, docConfig, executorConfig, clusterConfig, bucketConfig, 1); + handler = new DocumentV1ApiHandler(clock, Duration.ofMillis(1), metric, metrics, access, docConfig, + executorConfig, clusterConfig, bucketConfig, Executors.newFixedThreadPool(2)); int writers = 4; int queueFill = executorConfig.maxThrottled() - writers; |