Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-14491

Adding entries with putAll does not add metadata version - following replaceWithVersion will end with a timout

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 15.0.0.Dev01, 14.0.7.Final
    • None
    • None
    • None

    Description

      Adding entry with putAll and update directly replaceWithVersion will cause a timeout.

      Client logging

      ~~~

      SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
      SLF4J: Defaulting to no-operation (NOP) logger implementation
      SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
      Jan 31, 2023 10:43:03 AM org.infinispan.client.hotrod.RemoteCacheManager actualStart
      INFO: ISPN004021: Infinispan version: Red Hat Data Grid 'Infinispan 13.0.10.Final-redhat-00001' 8.3.1.GA
      Added 1->A
      Existing -> MetadataValueImpl [created=-1, lifespan=-1, lastUsed=-1, maxIdle=-1, getVersion()=0, getValue()=A]
      Jan 31, 2023 10:44:03 AM org.infinispan.client.hotrod.impl.operations.RetryOnFailureOperation handleException
      WARN: ISPN004098: Closing connection [id: 0xcae9f4f7, L:/127.0.0.1:42212 - R:localhost/127.0.0.1:11222] due to transport error
      java.net.SocketTimeoutException: ReplaceIfUnmodifiedOperation{test, key=[B0x4A083177697468416C6C, value=[B0x4A0142, flags=6, connection=localhost/127.0.0.1:11222} timed out after 60000 ms
          at org.infinispan.client.hotrod.impl.operations.HotRodOperation.run(HotRodOperation.java:182)
          at io.netty.util.concurrent.PromiseTask.runTask(PromiseTask.java:98)
          at io.netty.util.concurrent.ScheduledFutureTask.run(ScheduledFutureTask.java:170)
          at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164)
          at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:469)
          at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:384)
          at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986)
          at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
          at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
          at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
          at java.base/java.lang.Thread.run(Thread.java:834)

      ~~~

      Client code

      ~~~

              String key = "1withAll";
              HashMap<String, String> values = new HashMap<>();
              values.put(key, "A");
              remoteCache.putAll(values);

              System.out.println("Added 1->A" );
              MetadataValue<String> existingMetaDataValue = remoteCache.getWithMetadata(key);
              System.out.println("Existing -> " + existingMetaDataValue );
              remoteCache.replaceWithVersion(key, "B", existingMetaDataValue.getVersion()); // times out
              System.out.println("New value 1->" + remoteCache.get(key));

      ~~~

       

      Attachments

        Issue Links

          Activity

            People

              rh-ee-jbolina Jose Bolina
              rhn-support-wfink Wolf Fink
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: