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

Unable to get entries from newly started non-defined caches

    XMLWordPrintable

Details

    Description

      If you use hotrod to put entries into a cache which is not defined in standalone.xml, it will be started:

      15:35:50,676 INFO  [org.jboss.as.clustering.infinispan] (HotRodServerWorker-1) JBAS010281: Started nonDefinedCache cache from local container
      

      but when you try to retrieve the entry back, you'll get null.

      RemoteCacheManager rcm = new RemoteCacheManager(new ConfigurationBuilder().addServer().host("localhost").port(11222).build());
      RemoteCache<String, String> cache = rcm.getCache("nonDefinedCache");
      cache.put("key", "value");
      cache.get("key"); // returns null
      

      Happens in the current server snapshot.
      A while back you'd get this

      WARN: ISPN004005: Error received from the server: org.infinispan.server.hotrod.CacheNotFoundException: Cache with name 'nonDefinedCache' not found amongst the configured caches
      

      So it seems we're somewhere in the middle now (not throwing exception, but also not working). The documentation here is also wrong https://github.com/infinispan/infinispan/blob/master/client/hotrod-client/src/main/java/org/infinispan/client/hotrod/RemoteCacheManager.java#L511 .

      Attachments

        Issue Links

          Activity

            People

              rh-ee-galder Galder ZamarreƱo
              jmarkos Jakub Markos (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: