6 Replies Latest reply on Dec 18, 2013 1:43 AM by Binu S

    Infinispan cache monitoring and management

    Binu S Newbie

      We are using JBoss infinispan cache for enterprise application. Currently for monitoring cache we depends on JConsole, which tells the figures like no:of hits, total entries, elapsed time etc...Is there any other monitoring tool which helps in following;


      1. query cache for a specific data (probably using the key) , main purpose is verifying the application behaviour.

      2. clear the cache


      The end user is like an administrator and will be operated outside from deployment.


      Note: By using RHQ whetehr it possible ?

        • 1. Re: Infinispan cache monitoring and management
          Tristan Tarrant Master

          We do provide RHQ/JON plugins for both embedded and client/server modes, which allow collecting metrics and performing some types of operation (clearing a cache is one of them).

          However we do not have any support for inspecting and modifying entries in the cache through RHQ/JON, whereas the CLI does.

          1 of 1 people found this helpful
          • 2. Re: Infinispan cache monitoring and management
            Binu S Newbie

            Our requirement scope is below;


            1. Inspect cache - for specific content (mainly using key)

            2. Clear cache


            Could I get some details about the CLI tool you mentioned.

            • 3. Re: Infinispan cache monitoring and management
              Romain Pelisse Apprentice

              Hi Binu,


              I think you'll find the information you are looking for in the documentation on the CLI tool. (also note that quickly googling "InfiniSpan CLI" you'll have land there )



              1 of 1 people found this helpful
              • 4. Re: Infinispan cache monitoring and management
                Binu S Newbie

                Thanks Romain, seems a perfect one.

                • 5. Re: Infinispan cache monitoring and management
                  Binu S Newbie

                  Hi Romain,


                  If we are using Infinispan version (Infinispan subsystem) available with JBoss server, will this CLI tool works ?  In our case the Infinispan cache is a subsystem and will be start/stop as part of JBoss server initiation.

                  We are using JBoss 7.2.0 version and Infinispan 5.2.1 version.


                  The details;


                  1. We are using Cache support in Spring environment (version 3.2).

                  2. Using @Cacheable annotation, mainly method level caching

                  3. The Cache implementation uses Infinispan subsytem as Cache store..

                  4. The cacheManager created in Spring xml, like below

                       <!-- Infinispan cache manager -->

                       <bean id="cacheManager"





                  5. The cache defined as follows in JBoss configuration xml (standalone.xml)

                      <subsystem xmlns="urn:jboss:domain:infinispan:1.4">

                      <cache-container name="abcContainer" default-cache="default"

                      jndi-name="abcContainer" start="EAGER">

                      <local-cache name="default">

                     <transaction mode="NON_XA" />

                    <eviction strategy="LRU" max-entries="1000" />

                    <expiration lifespan="600000" max-idle="0" />


                    <local-cache name="cache-1" start="EAGER">

                    <transaction mode="NON_XA" />

                    <eviction strategy="LRU" max-entries="100" />

                    <expiration lifespan="300000" max-idle="100000" />



                  like this we have some more Cache systems with different names...


                  So the requirement is to check/verify the content of each Cache at specific point of time,

                  clear the cache.

                  • 6. Re: Infinispan cache monitoring and management
                    Binu S Newbie



                    Currently I am able to connect to Infinispan instance running on JBoss As and able to query cache container, I am using following command to connect


                    >connect remoting://host:port


                    But I am facing issue with connecting to a remote server, i.e the JBoss server running on a different machine and infinispan-CLI command tool trying to connect from remote location.


                    Example: The remote server where JBoss AS is running (included the infinispan-CLI server) is and port is 9999

                    Case-1. >connect remoting:// , following error on client side, and no error on server

                    Remote connection failed: javax.security.sasl.SaslException: Authentication failed: all available authentication mechanisms failed


                    Case-2. >connect remoting://user@, where user is username of Management user. following error on client side;

                    Failed to retrieve RMIServer stub: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: non-JRMP server at remote endpoint]

                    following error on server side;

                    ERROR [org.jboss.remoting.remote.connection] (Remoting "hostname:MANAGEMENT" read-1) JBREM000200: Remote connection failed: java.io.IOExcept

                    ion: Received an invalid message length of 1246907721


                    Note: I created a Management user using add-user.[bat|sh] and added <server-identities> under <security-realm name="ManagementRealm"> like below, the secret value was given by the add-user script

                    <security-realm name="ManagementRealm">


                                <secret value="XXxxXXXxxX="/>



                    But still the issue persists same, could anyone have any idea about this issue.