public class ProcessingUnitContextLoader extends ContextLoader
ContextLoader
. Different in two aspects:
The first, it automatillcay loads the binded META-INF/spring/pu.xml
(binded into the servlet
context) as the parent application context. See loadParentContext(javax.servlet.ServletContext)
.
Second, it overrides the creation of WebApplicationContext
and
automatically adds ClusterInfo
and BeanLevelProperties
handling. It also delegates the objects to the web context level Spring application context.
CONFIG_LOCATION_PARAM, CONTEXT_CLASS_PARAM, CONTEXT_ID_PARAM, CONTEXT_INITIALIZER_CLASSES_PARAM, LOCATOR_FACTORY_KEY_PARAM, LOCATOR_FACTORY_SELECTOR_PARAM
Constructor and Description |
---|
ProcessingUnitContextLoader() |
Modifier and Type | Method and Description |
---|---|
protected WebApplicationContext |
createWebApplicationContext(javax.servlet.ServletContext servletContext,
ApplicationContext parent)
Creates a Spring
WebApplicationContext - ProcessingUnitWebApplicationContext . |
WebApplicationContext |
initWebApplicationContext(javax.servlet.ServletContext servletContext) |
protected ApplicationContext |
loadParentContext(javax.servlet.ServletContext servletContext)
Returns the application context bound under
JeeProcessingUnitContainerProvider.APPLICATION_CONTEXT_CONTEXT
within the servlet context. |
closeWebApplicationContext, configureAndRefreshWebApplicationContext, createWebApplicationContext, customizeContext, determineContextClass, determineContextInitializerClasses, getCurrentWebApplicationContext
public WebApplicationContext initWebApplicationContext(javax.servlet.ServletContext servletContext) throws IllegalStateException, BeansException
initWebApplicationContext
in class ContextLoader
IllegalStateException
BeansException
protected ApplicationContext loadParentContext(javax.servlet.ServletContext servletContext) throws BeansException
JeeProcessingUnitContainerProvider.APPLICATION_CONTEXT_CONTEXT
within the servlet context. This will act as the parent application context.loadParentContext
in class ContextLoader
BeansException
protected WebApplicationContext createWebApplicationContext(javax.servlet.ServletContext servletContext, ApplicationContext parent) throws BeansException
WebApplicationContext
- ProcessingUnitWebApplicationContext
.
Adds support to ClusterInfo
and BeanLevelProperties
processors. The objects
themself are bounded in the ServletContext
.
createWebApplicationContext
in class ContextLoader
BeansException
Copyright © GigaSpaces.