Class SessionsFactory


  • public class SessionsFactory
    extends java.lang.Object
    INTERNAL: Builds EclipseLink Sessions from the XML Session Config model. Model classes that are not built, are processed only.
    Version:
    1.0
    Author:
    Guy Pelletier
    • Field Detail

      • m_sessions

        protected java.util.Map<java.lang.String,​Session> m_sessions
      • m_logLevels

        protected java.util.Map<java.lang.String,​java.lang.Integer> m_logLevels
      • m_classLoader

        protected java.lang.ClassLoader m_classLoader
    • Constructor Detail

      • SessionsFactory

        public SessionsFactory()
        INTERNAL:
    • Method Detail

      • buildSessionConfigs

        public java.util.Map<java.lang.String,​Session> buildSessionConfigs​(SessionConfigs eclipseLinkSessions,
                                                                                 java.lang.ClassLoader classLoader)
        INTERNAL: To build EclipseLink sessions, users must call this method with a SessionConfigs object returned from an OX read in the XMLSessionsConfigLoader.
        Parameters:
        eclipseLinkSessions - object returned from an OX read in the XMLSessionsConfigLoader
        classLoader - class loader used in the XMLSessionsConfigLoader
        Returns:
        EclipseLink sessions
      • processSessionCustomizer

        protected void processSessionCustomizer​(SessionConfig sessionConfig,
                                                AbstractSession session)
        INTERNAL: Process the user inputed session customizer class. Will be run at the end of the session build process
      • buildSession

        protected AbstractSession buildSession​(SessionConfig sessionConfig)
        INTERNAL: Build the correct session based on the session config type
      • buildDatabaseSessionConfig

        protected AbstractSession buildDatabaseSessionConfig​(DatabaseSessionConfig databaseSessionConfig)
        INTERNAL: Wrapped by the getSession() call, therefore, config can't be null at this point.
      • processDatabaseSessionConfig

        protected void processDatabaseSessionConfig​(DatabaseSessionConfig sessionConfig,
                                                    AbstractSession session)
        INTERNAL Process a DatabaseSessionConfig object.
      • buildServerSessionConfig

        protected AbstractSession buildServerSessionConfig​(ServerSessionConfig serverSessionConfig)
        INTERNAL: Builds a server server from the given ServerSessionConfig.
      • createSession

        protected DatabaseSessionImpl createSession​(DatabaseSessionConfig sessionConfig,
                                                    Login login)
        INTERNAL: Return a DatabaseSession object from it's config object using either the project classes or project XML files.
      • prepareProjectLogin

        protected void prepareProjectLogin​(Project project,
                                           Login login)
        INTERNAL: Return the correct session type from the sessionConfig
      • loadProjectConfig

        protected Project loadProjectConfig​(ProjectConfig projectConfig)
        INTERNAL: Load a projectConfig from the session.xml file. This method will determine the proper loading scheme, that is, for a class or xml project.
      • buildLogin

        protected Login buildLogin​(LoginConfig loginConfig)
        INTERNAL: Build the correct login based on the login config type
      • buildEISLoginConfig

        protected Login buildEISLoginConfig​(EISLoginConfig eisLoginConfig)
        INTERNAL: Wrapped by the getLogin() call, therefore, config can't be null at this point.
      • buildXMLLoginConfig

        protected Login buildXMLLoginConfig​(XMLLoginConfig xmlLoginConfig)
        INTERNAL: Wrapped by the getLogin() call, therefore, config can't be null at this point.
      • buildDatabaseLoginConfig

        protected Login buildDatabaseLoginConfig​(DatabaseLoginConfig databaseLoginConfig)
        INTERNAL: Build a DatabaseLogin for the given Session Wrapped by the getLogin() call, therefore, config can't be null at this point.
      • processLoginConfig

        protected void processLoginConfig​(LoginConfig loginConfig,
                                          DatasourceLogin login)
        INTERNAL: Process the common elements of a Login.
      • processPoolsConfig

        protected void processPoolsConfig​(PoolsConfig poolsConfig,
                                          ServerSession serverSession)
        INTERNAL: Process the PoolsConfig object.
      • processSequenceConnectionPoolConfig

        protected void processSequenceConnectionPoolConfig​(ConnectionPoolConfig poolConfig,
                                                           ServerSession serverSession)
        INTERNAL: Process a SequenceConnectionPoolConfig object.
      • processServerPlatformConfig

        protected void processServerPlatformConfig​(ServerPlatformConfig platformConfig,
                                                   ServerPlatform platform)
        INTERNAL: Process a ServerPlatformConfig object.
      • processConnectionPolicyConfig

        protected void processConnectionPolicyConfig​(ConnectionPolicyConfig connectionPolicyConfig,
                                                     ServerSession serverSession)
        INTERNAL: Process the common elements from a ConnectionPoolConfig
      • processSessionConfig

        protected void processSessionConfig​(SessionConfig sessionConfig,
                                            AbstractSession session)
        INTERNAL: Process the common elements from a SessionConfig.
      • buildSequence

        protected Sequence buildSequence​(SequenceConfig sequenceConfig)
        INTERNAL: Builds a Sequence from the given SequenceConfig.
      • buildRMIIIOPTransportManagerConfig

        protected void buildRMIIIOPTransportManagerConfig​(RMIIIOPTransportManagerConfig tmConfig,
                                                          RemoteCommandManager rcm)
        INTERNAL: Left this in for now since in the future we may add more IIOP specific configurations?
      • buildDefaultSessionLogConfig

        protected SessionLog buildDefaultSessionLogConfig​(DefaultSessionLogConfig defaultSessionLogConfig)
        INTERNAL: Wrapped by the getSessionLog() call, therefore, config can't be null at this point.
      • processLogConfig

        protected void processLogConfig​(LogConfig logConfig,
                                        SessionLog log)
        INTERNAL:
      • buildSessionBrokerConfig

        protected SessionBroker buildSessionBrokerConfig​(SessionBrokerConfig sessionBrokerConfig)
        INTERNAL: Builds a session broker from the given SessionBrokerConfig.