|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.rmi.server.RemoteObject
java.rmi.server.RemoteServer
java.rmi.server.UnicastRemoteObject
com.ibm.di.api.remote.impl.SessionImpl
public class SessionImpl
Field Summary |
---|
Fields inherited from class java.rmi.server.RemoteObject |
---|
ref |
Constructor Summary | |
---|---|
SessionImpl(RMIClientSocketFactory aClientSF,
RMIServerSocketFactory aServerSF)
|
|
SessionImpl(String aUserId,
RMIClientSocketFactory aClientSF,
RMIServerSocketFactory aServerSF)
|
Method Summary | |
---|---|
void |
addEventListener(DIEventListener aListener,
String aTypeFilter,
String aIdFilter)
Registers an Event Listener with the Session. |
void |
checkInAndLeaveCheckedOut(MetamergeConfig aConfiguration,
String aRelativePath)
Checks in the specified configuration and leaves it checked out. |
void |
checkInConfiguration(MetamergeConfig aConfiguration,
String aRelativePath)
Saves the specified configuration and releases the lock. |
void |
checkInConfiguration(MetamergeConfig aConfiguration,
String aRelativePath,
boolean aEncrypt)
Encrypts and saves the specified configuration and releases the lock. |
MetamergeConfig |
checkOutConfiguration(String aRelativePath)
Checks out the specified configuration. |
MetamergeConfig |
checkOutConfiguration(String aRelativePath,
String aPassword)
Checks out the specified password protected configuration. |
ConfigInstance |
checkOutConfigurationAndLoad(String aRelativePath)
Checks out the specified configuration and starts a temporary Config Instance on the Server. |
ConfigInstance |
checkOutConfigurationAndLoad(String aRelativePath,
String aPassword)
Checks out the specified configuration and starts a temporary Config Instance on the Server. |
ConfigInstance |
createNewConfigInstance(String aConfigUrl)
|
ConfigInstance |
createNewConfigInstance(String aConfigUrl,
String aPassword)
|
MetamergeConfig |
createNewConfiguration(String aRelativePath,
boolean aOverwrite)
Creates a new empty configuration and immediately checks it out. |
ConfigInstance |
createNewConfigurationAndLoad(String aRelativePath,
boolean aOverwrite)
Creates a new empty configuration, immediately checks it out and loads a temporary Config Instance on the Server. |
AssemblyLine[] |
getAssemblyLines()
Returns started AssemblyLines corresponding to the currently started configurations. |
String |
getConfigFolderPath()
Gets the value of the api.config.folder property in the remote server as a complete path. |
ConfigInstance |
getConfigInstance(String aConfigId)
Returns configuration instance corresponding to a specific configuration ID. |
ConfigInstance[] |
getConfigInstances()
Returns all currently started configuration instances. |
EventHandler[] |
getEventHandlers()
Returns started EventHandlers corresponding to the currently started configurations. |
Identity |
getIdentity()
|
SecurityRegistry |
getSecurityRegistry()
Returns information about the restrictions the current user has. |
ServerInfo |
getServerInfo()
Retrieves the Server information. |
SystemLog |
getSystemLog()
Returns information about the System logging. |
SystemQueue |
getSystemQueue()
Gets the remote Server API SystemQueue representation object |
TombstoneManager |
getTombstoneManager()
Returns the TombstoneManager object. |
Object |
invokeCustom(String aCustomClassName,
String aMethodName,
Object[] aParams)
Invokes the specified method from the specified class. |
Object |
invokeCustom(String aCustomClassName,
String aMethodName,
Object[] aParamsValue,
String[] aParamsClass)
Invokes the specified method from the specified class. |
boolean |
isConfigurationCheckedOut(String aRelativePath)
Checks if the specified configuration is checked out on the Server. |
boolean |
isSSLon()
Checks if current session is over SSL. |
ArrayList |
listAllConfigurations()
Returns a list all configurations in the directory subtree of the Server configuration codebase folder. |
ArrayList |
listConfigurations(String aRelativePath)
Returns a list of all configurations in the specified folder. |
ArrayList |
listFolders(String aRelativePath)
Returns a list of the child folders of the specified folder. |
boolean |
releaseConfigurationLock(String aRelativePath)
Administratively releases the lock of the specified configuration. |
boolean |
removeEventListener(DIEventListener aListener)
Unregisters an Event Listener with the Session. |
void |
sendCustomNotification(String aType,
String aId,
Object aData)
Sends a custom, user defined notification to all registered listeners. |
void |
sendEventToACT(Serializable event)
Processes an event by the Active Correlation Technology engine of the TDI server. |
void |
shutDownServer()
Shuts down the ITDI server. |
void |
shutDownServer(int aExitCode)
Shuts down the TDI Server with the specified exit code. |
ConfigInstance |
startConfigInstance(String aConfigUrl)
Starts a new Config Instance on the Server with the configuration given. |
ConfigInstance |
startConfigInstance(String aConfigUrl,
boolean aKeepAlive,
String aPassword)
Starts a new Config Instance on the Server with the configuration given. |
boolean |
undoCheckOut(String aRelativePath)
Releases the lock on the specified configuration, thus aborting all changes being done. |
Methods inherited from class java.rmi.server.UnicastRemoteObject |
---|
clone, exportObject, exportObject, exportObject, unexportObject |
Methods inherited from class java.rmi.server.RemoteServer |
---|
getClientHost, getLog, setLog |
Methods inherited from class java.rmi.server.RemoteObject |
---|
equals, getRef, hashCode, toString, toStub |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public SessionImpl(RMIClientSocketFactory aClientSF, RMIServerSocketFactory aServerSF) throws DIException, RemoteException
DIException
RemoteException
public SessionImpl(String aUserId, RMIClientSocketFactory aClientSF, RMIServerSocketFactory aServerSF) throws DIException, RemoteException
DIException
RemoteException
Method Detail |
---|
public ServerInfo getServerInfo() throws DIException, RemoteException
Session
getServerInfo
in interface Session
DIException
- if an error occurs while retrieving the Server information.
RemoteException
- if a communication-related exception occurs.public ConfigInstance[] getConfigInstances() throws DIException, RemoteException
Session
getConfigInstances
in interface Session
DIException
- if an error occurs while retrieving the information
about the currently started configuration instances.
RemoteException
- if a communication-related exception occurs.public ConfigInstance getConfigInstance(String aConfigId) throws DIException, RemoteException
Session
getConfigInstance
in interface Session
aConfigId
- the ID of the wanted configuration.
DIException
- if an error occurs while retrieving the information.
RemoteException
- if a communication-related exception occurs.public AssemblyLine[] getAssemblyLines() throws DIException, RemoteException
Session
getAssemblyLines
in interface Session
DIException
- if an error occurs while retrieving the information
about the AssemblyLines.
RemoteException
- if a communication-related exception occurs.public EventHandler[] getEventHandlers() throws DIException, RemoteException
Session
getEventHandlers
in interface Session
DIException
- if an error occurs while retrieving the information
about the EventHandlers.
RemoteException
- if a communication-related exception occurs.public ConfigInstance startConfigInstance(String aConfigUrl) throws DIException, RemoteException
Session
startConfigInstance
in interface Session
aConfigUrl
- The URL where the configuration file is loaded from or the
Solution Name of the configuration file.
Only configuration files located in the configuration codebase folder can be
referenced by Solution Name.
DIException
- if an error occurs on starting the new Config Instance.
RemoteException
- if a communication-related exception occurs.public ConfigInstance startConfigInstance(String aConfigUrl, boolean aKeepAlive, String aPassword) throws DIException, RemoteException
Session
startConfigInstance
in interface Session
aConfigUrl
- The URL where the configuration file is loaded from or the
Solution Name of the configuration file.aKeepAlive
- When true
the Config Instance will stay alive even
when no threads are running, when false
the Config Instance will automatically
terminate when its last thread terminates.aPassword
- Specify the pasword of the conofiguration when it is password-protected; specify
null
when the configuration is not password-protected.
DIException
- if an error occurs on starting the new Config Instance.
RemoteException
- if a communication-related exception occurs.public ConfigInstance createNewConfigInstance(String aConfigUrl) throws DIException, RemoteException
createNewConfigInstance
in interface Session
aConfigUrl
- The URL of the new configuration file to be created.
DIException
- if an error occurs while creating the new Config Instance.
RemoteException
- if a communication-related exception occurs.public ConfigInstance createNewConfigInstance(String aConfigUrl, String aPassword) throws DIException, RemoteException
createNewConfigInstance
in interface Session
aConfigUrl
- The URL of the new configuration file to be created.aPassword
- If this parameter is not null
, the new configuration will
be protected with the given password.
DIException
- if an error occurs while creating the new Config Instance.
RemoteException
- if a communication-related exception occurs.public void shutDownServer() throws DIException, RemoteException
Session
shutDownServer
in interface Session
DIException
- if an error occurs while shutting down the server.
RemoteException
- if a communication-related exception occurs.public void shutDownServer(int aExitCode) throws DIException, RemoteException
Session
shutDownServer
in interface Session
aExitCode
- the exit code used to shut down TDI Server.
DIException
- if an error occurs while shutting down the server.
RemoteException
- if a communication-related exception occurs.public SecurityRegistry getSecurityRegistry() throws DIException, RemoteException
Session
getSecurityRegistry
in interface Session
DIException
- if an error occurs while retrieving security information.
RemoteException
- if a communication-related exception occurs.public SystemLog getSystemLog() throws DIException, RemoteException
Session
getSystemLog
in interface Session
DIException
- if an error occurs while retrieving the System logging information.
RemoteException
- if a communication-related exception occurs.public TombstoneManager getTombstoneManager() throws DIException, RemoteException
Session
getTombstoneManager
in interface Session
DIException
- if an error occurs while getting the TombstoneManager.
RemoteException
- if a communication-related exception occurs.public void addEventListener(DIEventListener aListener, String aTypeFilter, String aIdFilter) throws DIException, RemoteException
Session
addEventListener
in interface Session
aListener
- The Event Listener to register with the Session.aTypeFilter
- A filter for the type of events.aIdFilter
- A filter for the id of events.
DIException
- if an error occurs while registering the listener.
RemoteException
- if a communication-related exception occurs.public boolean removeEventListener(DIEventListener aListener) throws DIException, RemoteException
Session
removeEventListener
in interface Session
aListener
- The Event Listener to unregister.
DIException
- if an error occurs while unregistering the listener.
RemoteException
- if a communication-related exception occurs.public boolean isSSLon() throws DIException, RemoteException
Session
isSSLon
in interface Session
DIException
- if an error occurs while retrieving the information.
RemoteException
- if a communication-related exception occurs.public boolean releaseConfigurationLock(String aRelativePath) throws DIException, RemoteException
Session
releaseConfigurationLock
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs during releasing the lock.
RemoteException
- if a communication-related exception occurs.public boolean undoCheckOut(String aRelativePath) throws DIException, RemoteException
Session
undoCheckOut
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs during releasing the lock.
RemoteException
- if a communication-related exception occurs.public ArrayList listConfigurations(String aRelativePath) throws DIException, RemoteException
Session
listConfigurations
in interface Session
aRelativePath
- A folder relative to the Server configuration codebase folder.
DIException
- If an error occurs while retrieving configurations.
RemoteException
- if a communication-related exception occurs.public ArrayList listFolders(String aRelativePath) throws DIException, RemoteException
Session
listFolders
in interface Session
aRelativePath
- A folder relative to the Server configuration codebase folder.
DIException
- If an error occurs while retrieving child folder.
RemoteException
- if a communication-related exception occurs.public ArrayList listAllConfigurations() throws DIException, RemoteException
Session
listAllConfigurations
in interface Session
DIException
- If an error occurs while retrieving configurations.
RemoteException
- if a communication-related exception occurs.public MetamergeConfig checkOutConfiguration(String aRelativePath) throws DIException, RemoteException
Session
checkOutConfiguration
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs while checking out the configuration.
RemoteException
- if a communication-related exception occurs.public MetamergeConfig checkOutConfiguration(String aRelativePath, String aPassword) throws DIException, RemoteException
Session
checkOutConfiguration
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).aPassword
- Specify the password for password protected configurations.
DIException
- If an error occurs while checking out the configuration.
RemoteException
- if a communication-related exception occurs.public ConfigInstance checkOutConfigurationAndLoad(String aRelativePath, String aPassword) throws DIException, RemoteException
Session
checkOutConfigurationAndLoad
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).aPassword
- Specify the password for password protected configurations.
DIException
- If an error occurs while checking out the configuration.
RemoteException
- if a communication-related exception occurs.public ConfigInstance checkOutConfigurationAndLoad(String aRelativePath) throws DIException, RemoteException
Session
checkOutConfigurationAndLoad
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs while checking out the configuration.
RemoteException
- if a communication-related exception occurs.public void checkInConfiguration(MetamergeConfig aConfiguration, String aRelativePath) throws DIException, RemoteException
Session
checkInConfiguration
in interface Session
aConfiguration
- The MetamergeConfig object representing the configuration to
be checked in.aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs while checking in the configuration.
RemoteException
- if a communication-related exception occurs.public void checkInConfiguration(MetamergeConfig aConfiguration, String aRelativePath, boolean aEncrypt) throws DIException, RemoteException
Session
checkInConfiguration
in interface Session
aConfiguration
- The MetamergeConfig object representing the configuration to
be checked in.aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).aEncrypt
- If set to true, the configuration will be encrypted on the Server.
DIException
- If an error occurs while checking in the configuration.
RemoteException
- if a communication-related exception occurs.public void checkInAndLeaveCheckedOut(MetamergeConfig aConfiguration, String aRelativePath) throws DIException, RemoteException
Session
checkInAndLeaveCheckedOut
in interface Session
aConfiguration
- The MetamergeConfig object representing the configuration to
be checked in.aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs while checking in the configuration.
RemoteException
- if a communication-related exception occurs.public MetamergeConfig createNewConfiguration(String aRelativePath, boolean aOverwrite) throws DIException, RemoteException
Session
createNewConfiguration
in interface Session
aRelativePath
- The path of the new configuration file relative to the Server
configuration codebase folder.aOverwrite
- Specify whether to overwrite or not an already exising configuration file.
DIException
- If an error occurs while creating the new configuration.
RemoteException
- if a communication-related exception occurs.public ConfigInstance createNewConfigurationAndLoad(String aRelativePath, boolean aOverwrite) throws DIException, RemoteException
Session
createNewConfigurationAndLoad
in interface Session
aRelativePath
- The path of the new configuration file relative to the Server
configuration codebase folder.aOverwrite
- Specify whether to overwrite or not an already exising configuration file.
DIException
- If an error occurs while creating the new configuration.
RemoteException
- if a communication-related exception occurs.public boolean isConfigurationCheckedOut(String aRelativePath) throws DIException, RemoteException
Session
isConfigurationCheckedOut
in interface Session
aRelativePath
- The path to the configuration relative to the Server configuration codebase
folder or the Solution Name of the configuration (the configuration must be inside the configuration codebase
folder).
DIException
- If an error occurs while checking the configuration.
RemoteException
- if a communication-related exception occurs.public void sendCustomNotification(String aType, String aId, Object aData) throws DIException, RemoteException
Session
sendCustomNotification
in interface Session
aType
- Notification type, will be automatically prefixed with "user."aId
- Notification ID, usually identifies the object this event originated from.aData
- Custom user data. Make sure the object passed is serializable if you want
to send this event notification in a remote context.
DIException
- If an error occurs while sending the notification.
RemoteException
- if a communication-related exception occurs.public SystemQueue getSystemQueue() throws DIException, RemoteException
Session
getSystemQueue
in interface Session
DIException
- If the System Queue is turned off or the System
Queue cannot be initialized
RemoteException
- If the Server API RMI connection failspublic String getConfigFolderPath()
Session
getConfigFolderPath
in interface Session
public Identity getIdentity()
public Object invokeCustom(String aCustomClassName, String aMethodName, Object[] aParams) throws DIException, RemoteException
Session
invokeCustom
method. The usage of this method can be turned on/off. There
is a property in the global.properties file called api.custom.method.invoke.on. If this
property is set to true then this method can be invoked, otherwise an exception is
thrown if this method is invoked. There is a restriction on the
classes which can be directly invoked. The allowed classes are described in another property in
the global.properties file called api.custom.method.invoke.allowed.classes. Only
classes listed in this property can be directly invoked by this method. If a user tries to
invoke a class which is not in this list then an exception is thrown.
invokeCustom
in interface Session
aCustomClassName
- The class containing the method to be invoked.aMethodName
- The name of the method to be invoked.aParams
- Array of parameters used by the invoked method.
DIException
- If an error occurs while invoking the method.
RemoteException
- If a communication-related exception occurs.public Object invokeCustom(String aCustomClassName, String aMethodName, Object[] aParamsValue, String[] aParamsClass) throws DIException, RemoteException
Session
invokeCustom
methods
is that when using this method the user MUST specify the parameters' type.
The usage of this method can be turned on/off. There
is a property in the global.properties file called api.custom.method.invoke.on. If this
property is set to true then this method can be invoked, otherwise an exception is
thrown if this method is invoked. There is a restriction on the
classes which can be directly invoked. The allowed classes are described in another property in
the global.properties file called api.custom.method.invoke.allowed.classes. Only
classes listed in this property can be directly invoked by this method. If the user tries to
invoke a class which is not in this list then an exception is thrown.
invokeCustom
in interface Session
aCustomClassName
- The class containing the method to be invoked.aMethodName
- The name of the method to be invoked.aParamsValue
- Array of parameters used by the invoked method.aParamsClass
- The type of the parameters used by the invoked method.
DIException
- If an error occurs while invoking the method.
RemoteException
- If a communication-related exception occurs.public void sendEventToACT(Serializable event) throws DIException, RemoteException
Session
sendEventToACT
in interface Session
event
- Event to be processed by ACT engine - currently only
org.eclipse.hyades.logging.events.cbe.CommonBaseEvent is supported.
DIException
- An error occurred while processing the event or the event type is not supported.
RemoteException A communication-related error.
RemoteException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |