We are doing the load testing of our application , which uses the Couchbase DB. We are taking the thread dumps at regular intervals. In all the thread dumps after making call to couchbase threads are in BLOCKED state. We are not understating this behaviour
Below is the configuration of couchbase environment
DefaultCouchbaseEnvironment.builder().kvTimeout(5000).connectTimeout(7500)
.viewTimeout(7500).queryTimeout(7500).disconnectTimeout(10000)
.retryStrategy(BestEffortRetryStrategy.INSTANCE).build();
And we are doing simple CRUD operations like
JsonDocument doc =
JsonDocument.create("1236",
JsonObject.create().put("name", "test"));
bucket.insert(doc);
Below is the stackstrace what we obtained from Jstack
Thread 4257: (state = BLOCKED)
- sun.misc.Unsafe.park(boolean, long) @bci=0 (Compiled frame; information may be imprecise)
- java.util.concurrent.locks.LockSupport.parkNanos(java.lang.Object, long) @bci=20, line=215 (Compiled frame)
- java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedNanos(int, long) @bci=139, line=1037 (Compiled frame)
- java.util.concurrent.locks.AbstractQueuedSynchronizer.tryAcquireSharedNanos(int, long) @bci=25, line=1328 (Compiled frame)
- java.util.concurrent.CountDownLatch.await(long, java.util.concurrent.TimeUnit) @bci=10, line=277 (Compiled frame)
- com.couchbase.client.java.util.Blocking.blockForSingle(rx.Observable, long, java.util.concurrent.TimeUnit) @bci=32, line=72 (Compiled frame)
- com.couchbase.client.java.CouchbaseBucket.get(java.lang.String, long, java.util.concurrent.TimeUnit) @bci=17, line=118 (Compiled frame)
- com.couchbase.client.java.CouchbaseBucket.get(java.lang.String) @bci=9, line=113 (Compiled frame)
All our documents are in KBs. We have a cluster with 3 nodes. Java sdk version- 2.3.4
Please guide us in understanding the behaviour.
Thanks