Class PBAServerImpl

java.lang.Object
com.portal.bas.PBAServerImpl
All Implemented Interfaces:
PBAServer, Remote

public class PBAServerImpl extends Object implements PBAServer
PBAServerImpl is the implementation of the Business Application Server (BAS).
Author:
Larry Lynch-Freshner
  • Method Details

    • invokeInThread

      public static void invokeInThread(Runnable toRun)
      Deprecated.
      No replacement
      Runs a task in a thread-pool thread. Used to manage thread usage.

      Threading should be done on the client side, not on the server (for EJB compliance), so this method is deprecated.

      Parameters:
      toRun - the task to run
    • invokeInThread

      public static void invokeInThread(Runnable toRun, int priority)
      Deprecated.
      No replacement
      Runs a task in a thread-pool thread. Used to manage thread usage.

      Threading should be done on the client side, not on the server (for EJB compliance), so this method is deprecated.

      Parameters:
      toRun - the task to run
      priority - the thread priority to use
    • createDefaultConnection

      public PInfranetConnection createDefaultConnection() throws RemoteException
      Creates a default (property file driven) connection.
      Specified by:
      createDefaultConnection in interface PBAServer
      Returns:
      A PInfranetConnection object.
      Throws:
      RemoteException - thrown for errors
      See Also:
    • createConnection

      public PInfranetConnection createConnection(String name, String password, String connectInfo) throws RemoteException
      Deprecated.
      No replacement
      Creates an Portal connection, given specified login information.
      Specified by:
      createConnection in interface PBAServer
      Parameters:
      name - the user's login name
      password - the user's password, in clear text
      connectInfo - a Connection info string in the form: "pcp://<host>:<port>/service" where service is optional. This string may be null.
      Returns:
      A PInfranetConnection object
      Throws:
      RemoteException - thrown for errors
    • createConnection

      public PInfranetConnection createConnection(boolean useConnectionPool) throws RemoteException
      Creates an app controller which really represents a user session, not a connection to Portal.
      Specified by:
      createConnection in interface PBAServer
      Parameters:
      useConnectionPool - if true, the user session will use the connection pool for communication with Portal
      Returns:
      A new user session.
      Throws:
      RemoteException
    • createConnection

      public PInfranetConnection createConnection(PInfranetConnection session) throws RemoteException
      Creates a duplicate of session and returns it. A user session does not necessarily have a connection to the Portal server, but for historical reasons it's represented by PInfranetConnection whose name is misleading.
      Specified by:
      createConnection in interface PBAServer
      Parameters:
      session - the session to be duplicated.
      Returns:
      A new user session or null if session is not an instance of PInfranetAppControllerImpl or PInfranetConnectionImpl.
      Throws:
      RemoteException
    • shutDown

      public void shutDown() throws RemoteException
      Does necessary clean-up for shut-down.
      Specified by:
      shutDown in interface PBAServer
      Throws:
      RemoteException
    • getPossibleConnections

      public String[] getPossibleConnections() throws RemoteException
      Deprecated.
      No replacement
      Gets a list of available Portal hosts to connect to.
      Specified by:
      getPossibleConnections in interface PBAServer
      Returns:
      A String array, where each element contains an available host and port in connection information format.
      Throws:
      RemoteException - thrown for errors
    • logRemote

      public void logRemote(String src, String msg) throws RemoteException
      Logs a request from a client.
      Specified by:
      logRemote in interface PBAServer
      Parameters:
      src - the source identifier string
      msg - a message to log
      Throws:
      RemoteException - thrown for errors
    • main

      public static void main(String[] args)
      The BAS server entry when launched as a separate process.
      Parameters:
      args - command line arguments; not used