All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hazelcast.web.spring.package-info Maven / Gradle / Ivy

There is a newer version: 5.0-BETA-1
Show newest version
/*
 * Copyright (c) 2008-2015, Hazelcast, Inc. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

/**
 * Provides Spring aware Hazelcast based session replication.
 * 

* To use Spring aware Hazelcast to provide clustered sessions in a webapp, add the following components to your {@code web.xml}: * *

 * <filter>
 *   <filter-name>springAwareHazelcastWebFilter</filter-name>
 *   <filter-class>com.hazelcast.web.spring.SpringAwareWebFilter</filter-class>
 * </filter>
 * <filter-mapping>
 *   <filter-name>springAwareHazelcastWebFilter</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>
 * 
* *

* *

* {@link com.hazelcast.web.spring.SpringAwareWebFilter SpringAwareWebFilter} should be first * in the filter chain to ensure session actions performed in other filters in the chain are replicated. * Additionally, note that both the * {@link com.hazelcast.web.spring.SpringAwareWebFilter SpringAwareWebFilter} and * {@link com.hazelcast.web.SessionListener SessionListener} * must be registered for clustered sessions to work properly. The {@code SessionListener} informs the * {@code SpringAwareWebFilter} of session timeouts so it can update the cluster accordingly and * declaring * {@code org.springframework.security.web.session.HttpSessionEventPublisher HttpSessionEventPublisher} * as listener, which is used by Spring to be aware of session events, is not needed anymore * since {@link com.hazelcast.web.spring.SpringAwareWebFilter SpringAwareWebFilter} * already publishes events for Spring. *

* *

* For more information, see {@link com.hazelcast.web.WebFilter WebFilter}. *

*/ package com.hazelcast.web.spring;





© 2015 - 2024 Weber Informatics LLC | Privacy Policy