1 Reply Latest reply on Apr 5, 2016 11:33 AM by pferraro

    How to store session at remote infinispan

    carlos_hen

      I´m using:

      - Wildfly 8.2.1.Final

      - Infinispan Server 8.1.2.Final

       

      I have a remote infinispan server and it is working.

       

      I have the follow configuration in standalone.xml:

             

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

                  <cache-container name="web" default-cache="xpto" start="EAGER" module="org.wildfly.clustering.web.infinispan">

                      <local-cache name="xpto" batching="true">

                          <remote-store shared="true" preload="true" purge="false" cache="default" socket-timeout="60000" tcp-no-delay="true">

                              <remote-server outbound-socket-binding="infinispan-remote-server"/>

                              <write-behind />

                          </remote-store>

                      </local-cache>

               </subsystem>

       

      And about socket-binding:

       

              <outbound-socket-binding name="infinispan-remote-server">

                  <remote-destination host="127.0.0.1" port="11222"/>

              </outbound-socket-binding>

       

      But to run some webapp nothing is to sended to infinispan.

       

      Any idea?

        • 1. Re: How to store session at remote infinispan
          pferraro

          I would not recommend that configuration if your application is provided by multiple nodes, as it will result in stale reads on failover.  At a minimum, you should use an <invalidation-cache/>.  I also suggest removing <write-behind/> temporarily so you can see why the session state is not being sent to your remote infinispan cluster.