Hide Forgot
Created attachment 574851 [details] TRACE log for asynchronous cache store Description of problem: Running the following test suggests that storing entries into a cache with a defined async cache store blocks current thread until the entry is really stored in the database: https://svn.devel.redhat.com/repos/jboss-qa/edg/edg-functional-tests/trunk/remote/jdbc-cache-store/async-store-smoke/src/test/java/com/jboss/datagrid/cachestore/jdbc/stringbased/AsyncJdbcStringBasedCacheStoreTest.java Storing 200 entries via memcached client into a cache with async cache store took on my computer (and remote PostgreSQL DB) ~86 seconds while with synchronous cache store it took ~90 seconds. When I remove the cache store definition completely, it takes hundreds of milliseconds.
Created attachment 574853 [details] Example configuration - standalone.xml using H2 DB
I have tested this on H2 and MySQL locally, and could not reproduce it
Not sure this is reproducible with a locally running database. I've tested with H2 too and the numbers were 223ms for sync and 157ms for async. IMO it should be hundreds of milliseconds even for the remote DB as the calls should return immediately and storing the keys into the cache store should run in the background.