| <?xml version="1.0" encoding="UTF-8"?> |
| <web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" |
| version="3.0"> |
| |
| <filter> |
| <filter-name>hazelcast-filter</filter-name> |
| <filter-class>com.hazelcast.web.WebFilter</filter-class> |
| <!-- |
| Name of the distributed map storing |
| your web session objects |
| --> |
| <init-param> |
| <param-name>map-name</param-name> |
| <param-value>my-sessions</param-value> |
| </init-param> |
| <!-- How is your load-balancer configured? stick-session means all requests of |
| a session is routed to the node where the session is first created. This is |
| excellent for performance. If sticky-session is set to false, when a session |
| is updated on a node, entry for this session on all other nodes is invalidated. |
| You have to know how your load-balancer is configured before setting this |
| parameter. Default is true. --> |
| <init-param> |
| <param-name>sticky-session</param-name> |
| <param-value>false</param-value> |
| </init-param> |
| <!-- |
| Are you debugging? Default is false. |
| --> |
| <init-param> |
| <param-name>debug</param-name> |
| <param-value>false</param-value> |
| </init-param> |
| </filter> |
| <filter-mapping> |
| <filter-name>hazelcast-filter</filter-name> |
| <url-pattern>/*</url-pattern> |
| <dispatcher>FORWARD</dispatcher> |
| <dispatcher>INCLUDE</dispatcher> |
| <dispatcher>REQUEST</dispatcher> |
| </filter-mapping> |
| <listener> |
| <listener-class>com.hazelcast.web.SessionListener</listener-class> |
| </listener> |
| |
| </web-app> |