Save This Page
Home » jboss-5.0.0.CR1-src » org » jboss » ejb » plugins » [javadoc | source]
org.jboss.ejb.plugins
public class: StatefulSessionFilePersistenceManager [javadoc | source]
java.lang.Object
   org.jboss.mx.util.JBossNotificationBroadcasterSupport
      org.jboss.system.ServiceMBeanSupport
         org.jboss.ejb.plugins.StatefulSessionFilePersistenceManager

All Implemented Interfaces:
    StatefulSessionFilePersistenceManagerMBean, StatefulSessionPersistenceManager, org.jboss.kernel.spi.dependency.KernelControllerContextAware, ServiceMBean, MBeanRegistration, NotificationEmitter

A file-based stateful session bean persistence manager.

Reads and writes session bean objects to files by using the standard Java serialization mechanism.

Passivated state files are stored under: jboss-server-data-dir/storeDirectoryName/ejb-name-unique-id.

Since ejb-name is not unique across deployments we generate a unique-id to make sure that beans with the same EJB name do not collide.

Nested Class Summary:
static class  StatefulSessionFilePersistenceManager.DeleteFileAction   
static class  StatefulSessionFilePersistenceManager.MkdirsFileAction   
static class  StatefulSessionFilePersistenceManager.FISAction   
static class  StatefulSessionFilePersistenceManager.FOSAction   
Field Summary
public static final  String DEFAULT_STORE_DIRECTORY_NAME    The default store directory name ("sessions"). 
Fields inherited from org.jboss.system.ServiceMBeanSupport:
SERVICE_CONTROLLER_SIG,  log,  server,  serviceName
Method from org.jboss.ejb.plugins.StatefulSessionFilePersistenceManager Summary:
activateSession,   createId,   createService,   createdSession,   destroyService,   getPurgeEnabled,   getStoreDirectory,   getStoreDirectoryName,   passivateSession,   removePassivated,   removeSession,   setContainer,   setPurgeEnabled,   setStoreDirectoryName
Methods from org.jboss.system.ServiceMBeanSupport:
create,   createService,   destroy,   destroyService,   getDeploymentInfo,   getLog,   getName,   getNextNotificationSequenceNumber,   getObjectName,   getServer,   getServiceName,   getState,   getStateString,   jbossInternalCreate,   jbossInternalDescription,   jbossInternalDestroy,   jbossInternalLifecycle,   jbossInternalStart,   jbossInternalStop,   pojoChange,   pojoCreate,   pojoDestroy,   pojoStart,   pojoStop,   postDeregister,   postRegister,   preDeregister,   preRegister,   setKernelControllerContext,   start,   startService,   stop,   stopService,   unsetKernelControllerContext
Methods from org.jboss.mx.util.JBossNotificationBroadcasterSupport:
addNotificationListener,   getNotificationInfo,   handleNotification,   nextNotificationSequenceNumber,   removeNotificationListener,   removeNotificationListener,   sendNotification
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.jboss.ejb.plugins.StatefulSessionFilePersistenceManager Detail:
 public  void activateSession(StatefulSessionEnterpriseContext ctx) throws RemoteException 
 public Object createId(StatefulSessionEnterpriseContext ctx) throws Exception 
 protected  void createService() throws Exception 
    Setup the session data storage directory.

    Purges any existing session data found.

 public  void createdSession(StatefulSessionEnterpriseContext ctx) throws Exception 
    Non-operation.
 protected  void destroyService() throws Exception 
    Purge any data in the store, and then the store directory too.
 public boolean getPurgeEnabled() 
    Get the stale session state purge enabled flag. jmx:managed-attribute
 public File getStoreDirectory() 
    Returns the directory used to store session passivation state files. jmx:managed-attribute
 public String getStoreDirectoryName() 
    Get the sub-directory name under the server data directory where session data is stored. jmx:managed-attribute
 public  void passivateSession(StatefulSessionEnterpriseContext ctx) throws RemoteException 
 public  void removePassivated(Object id) 
    Removes the saved state file (if any) for the given session id.
 public  void removeSession(StatefulSessionEnterpriseContext ctx) throws RemoveException, RemoteException 
 public  void setContainer(Container con) 
 public  void setPurgeEnabled(boolean flag) 
    Set the stale session state purge enabled flag. jmx:managed-attribute
 public  void setStoreDirectoryName(String dirName) 
    Set the sub-directory name under the server data directory where session data will be stored.

    This value will be appened to the value of jboss-server-data-dir.

    This value is only used during creation and will not dynamically change the store directory when set after the create step has finished.