public abstract class AppService extends java.lang.Object implements MboServerInterface, Service, AppServiceRemote, Dependable, FixedLoggers, MaxRemoteProxy
MXServer,
Service,
ConfigFileAPPLOGGER, CRONTASKLOGGER, CRONTASKMGRLOGGER, CRONTASKMGRSQLLOGGER, DBCONNECTIONLOGGER, DDLOGGER, DMLOGGER, EVENTLOGGER, EXCEPTIONLOGGER, MAILLOGGER, MAXIMOLOGGER, MTLOGGER, NULLMBOPOINTER, SECURITY, SENDFAILEDLOGGER, SERVICELOGGER, SQLLOGGERappenderPrefix, LOGGERNAME_APP, LOGGERNAME_CRONTASK, LOGGERNAME_CRONTASKMGR, LOGGERNAME_DBCONNECTION, LOGGERNAME_DD, LOGGERNAME_DM, LOGGERNAME_DMPREVIEW, LOGGERNAME_EVENT, LOGGERNAME_EXCEPTION, LOGGERNAME_MAIL, LOGGERNAME_MAXIMO, LOGGERNAME_MT, LOGGERNAME_NULLMBOPOINTER, LOGGERNAME_SECURITY, LOGGERNAME_SENDFAILED, LOGGERNAME_SERVICE, LOGGERNAME_SQL, LOGGERNAME_SQL_CRONTASKMGR, LOGGERNAME_TXN, loggerPrefix| Constructor and Description |
|---|
AppService()
Default Constructor.
|
AppService(MXServer mxServer) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkSecurity(java.lang.String methodname,
UserInfo userInfo)
Look in MaxServSecurity to see if a SigOption has been defined for this servicename
and methodname.
|
void |
configure(java.util.Properties cf)
Configure the AppService.
|
void |
destroy()
Release system resources.
|
void |
freeDBConnection(ConnectionKey conKey)
Makes the connection used by the ConnectionKey object
available for others.
|
void |
freeMboSet()
Reduces the liveObjCount, invoked by java.rmi.server.Unreferenced.unreferenced()
implemented in psdi.mbo.MboSet
|
java.lang.String |
getCriteria(java.lang.String criteriaName)
Retrieve a criteria using its name.
|
java.lang.String |
getCurrentState()
Used for remote Management.
|
java.sql.Connection |
getDBConnection(ConnectionKey conKey)
Gets a database connection for reading and writing to the
database.
|
int |
getLiveObjCount()
Used to determine the "load" on this Application Service within this MXServer.
|
int |
getLoad()
Used by ServiceCoordinator
|
MaximoDD |
getMaximoDD()
Implementing MboServerInterface...
uses the mxServer.getMaximoDD(); |
MaxVarServiceRemote |
getMaxVar()
Return a reference to the MaxVar service
|
MboSetRemote |
getMboSet(java.lang.String setName,
UserInfo user)
This one should go away...
|
MXServer |
getMXServer()
Used by the delegates of this class.
|
java.lang.String |
getName()
Used by classes that contain this class
|
ProfileRemote |
getProfile(UserInfo userInfo)
Get the security profile for the specified user.
|
java.rmi.Remote |
getProxy() |
java.lang.String |
getSchemaOwner()
Returns the database schema owner.
|
java.lang.String |
getServiceInfo()
Returns Service name, author and version information.
|
MXLogger |
getServiceLogger()
Returns a logger to log messages related to this service.
|
MboSetRemote |
getSetForRelationship(java.lang.String relOwner,
java.lang.String relName,
java.lang.String[] relColumn,
java.lang.String[] relValue,
UserInfo userInfo)
This is used by the Java UI dialog boxes.
|
MboSetRemote |
getSetFromKeys(java.lang.String setName,
java.lang.String[] keyNames,
java.lang.String[][] keyValues,
UserInfo user)
This method constructs a MboSet to contain all the records based on their key values as
specified through the parameters.
|
java.lang.String[] |
getStateCmdList()
Used for remote Management.
|
java.lang.String[] |
getStateList()
Used for remote Management.
|
java.lang.String |
getURL()
Used by ServiceCoordinator
|
void |
init()
Initialize the Application Service.
|
void |
initCriteriaList(java.util.Hashtable criteriaTable)
Create the criteria list for use with getCriteria.
|
boolean |
isAppService()
Used by ServiceCoordinator
|
boolean |
isRunning()
Get the value of the running variable.
|
boolean |
isSingletonService()
Is used to setup singleton services, i.e.
|
void |
restart()
Indicates that the Service should reload any cached
information.
|
void |
setProxy(java.rmi.Remote proxy) |
void |
setRunning(boolean value)
Set the value of the running variable.
|
void |
setURL(java.lang.String url)
Used by ServiceCoordinator
|
void |
verifyUser(java.lang.String loginCheck,
java.lang.String passCheck,
UserInfo userinfo)
After a user has connected, re-verify the username and password.
|
boolean |
verifyUser(java.lang.String loginCheck,
java.lang.String passCheck,
UserInfo userinfo,
java.lang.String app,
java.lang.String reason,
java.lang.String transid,
java.lang.String[] keyvalue)
After a user has connected, re-verify the username and password.
|
public AppService()
throws java.rmi.RemoteException
java.rmi.RemoteExceptionpublic AppService(MXServer mxServer) throws java.rmi.RemoteException
srvEnv - -- the "Server Environment" this Service is being
created in.java.rmi.RemoteExceptionpublic boolean isRunning()
isRunning in interface Dependablepublic void setRunning(boolean value)
setRunning in interface Dependablepublic void configure(java.util.Properties cf)
public void setProxy(java.rmi.Remote proxy)
setProxy in interface MaxRemoteProxypublic java.rmi.Remote getProxy()
getProxy in interface MaxRemoteProxypublic void init()
public void destroy()
Servicepublic MXServer getMXServer()
public java.lang.String getName()
getName in interface AppServiceRemotegetName in interface ServicegetName in interface ServiceRemotepublic java.lang.String getURL()
getURL in interface AppServiceRemotegetURL in interface ServicegetURL in interface ServiceRemotepublic void setURL(java.lang.String url)
public int getLoad()
public boolean isAppService()
isAppService in interface ServiceisAppService in interface ServiceRemotepublic boolean isSingletonService()
isSingletonService in interface ServiceisSingletonService in interface ServiceRemotepublic java.lang.String getServiceInfo()
public MaxVarServiceRemote getMaxVar() throws MXException, java.rmi.RemoteException
getMaxVar in interface MboServerInterfaceMXExceptionjava.rmi.RemoteExceptionpublic ProfileRemote getProfile(UserInfo userInfo) throws MXException, java.rmi.RemoteException
getProfile in interface MboServerInterfaceuserInfo - MXExceptionjava.rmi.RemoteExceptionSecurityService.getProfile(psdi.security.UserInfo)public MaximoDD getMaximoDD()
getMaximoDD in interface MboServerInterfacepublic java.lang.String getSchemaOwner()
getSchemaOwner in interface MboServerInterfacegetSchemaOwner in interface AppServiceRemoteDBManagerpublic MboSetRemote getSetFromKeys(java.lang.String setName, java.lang.String[] keyNames, java.lang.String[][] keyValues, UserInfo user) throws MXException, java.rmi.RemoteException
getSetFromKeys in interface AppServiceRemotesetName - the name of the objectkeyNames - The name of the keys in the same order keyValues are specifiedkeyValues - Two dimentially string array. Each row contain the values of the
keys specified in keyNames in the same order. Each record is represented by a rowuser - userInfo objectMXExceptionjava.rmi.RemoteExceptiongetSetFromKeys(String, String[], String[][], UserInfo )public MboSetRemote getMboSet(java.lang.String setName, UserInfo user) throws MXException, java.rmi.RemoteException
getMboSet in interface MboServerInterfacegetMboSet in interface AppServiceRemoteMXExceptionjava.rmi.RemoteExceptionpublic void freeMboSet()
freeMboSet in interface MboServerInterfaceMboSetpublic int getLiveObjCount()
getLiveObjCount in interface AppServiceRemotepublic java.sql.Connection getDBConnection(ConnectionKey conKey)
getDBConnection in interface MboServerInterfacepublic void freeDBConnection(ConnectionKey conKey)
freeDBConnection in interface MboServerInterfacepublic java.lang.String getCurrentState()
throws java.rmi.RemoteException
getCurrentState in interface AppServiceRemotejava.rmi.RemoteExceptionpublic java.lang.String[] getStateList()
throws java.rmi.RemoteException
getStateList in interface AppServiceRemotejava.rmi.RemoteExceptionpublic java.lang.String[] getStateCmdList()
throws java.rmi.RemoteException
getStateCmdList in interface AppServiceRemotejava.rmi.RemoteExceptionpublic void restart()
throws java.rmi.RemoteException
restart in interface ServiceRemotejava.rmi.RemoteExceptionpublic void initCriteriaList(java.util.Hashtable criteriaTable)
throws MXException,
java.rmi.RemoteException
MXExceptionjava.rmi.RemoteExceptionpublic java.lang.String getCriteria(java.lang.String criteriaName)
throws java.rmi.RemoteException
getCriteria in interface AppServiceRemotejava.rmi.RemoteExceptionpublic void verifyUser(java.lang.String loginCheck,
java.lang.String passCheck,
UserInfo userinfo)
throws MXException,
java.rmi.RemoteException
verifyUser.
If the entered username is blocked, an error is thrown (signature / blockedUser).
If the entered username and password do not equal those used to log on,
an error is thrown (signature / badVerify).verifyUser in interface AppServiceRemoteloginCheck - The newly entered Login ID to be compared to the
logon loginid.passCheck - The newly entered password to be compared to the
logon password.userInfo - The current UserInfo.MXExceptionjava.rmi.RemoteExceptionverifyUser(String, String, UserInfo, String, String, String, String[])public boolean verifyUser(java.lang.String loginCheck,
java.lang.String passCheck,
UserInfo userinfo,
java.lang.String app,
java.lang.String reason,
java.lang.String transid,
java.lang.String[] keyvalue)
throws MXException,
java.rmi.RemoteException
verifyUser in interface MboServerInterfaceverifyUser in interface AppServiceRemoteloginCheck - The newly entered Login ID to be compared to the
logon loginid.passCheck - The newly entered password to be compared to the
logon password.userInfo - The current UserInfo.app - The application name (optional). Used for ESIG.reason - The reason code (optional). Used for ESIG.transid - The transaction ID (optional). Used for ESIG.keyvalue - Array of up to seven key values (optional).
Used for ESIG to identify a mbo in the main set for the app.MXExceptionjava.rmi.RemoteExceptionSignatureService.isBlocked(java.lang.String, psdi.security.UserInfo),
SignatureService.addLoginTracking(java.lang.String, boolean, psdi.security.UserInfo),
psdi.security.UserInfo#isUser,
SignatureService.isBlocked(java.lang.String, psdi.security.UserInfo),
psdi.security.SerucityService#isUserpublic MboSetRemote getSetForRelationship(java.lang.String relOwner, java.lang.String relName, java.lang.String[] relColumn, java.lang.String[] relValue, UserInfo userInfo) throws MXException, java.rmi.RemoteException
Given a relationship name and an array of String parameters, get the relationship, substitute the parameters, get the MboSet, and return the Set. This presumes that the bind variables in the relationship Sql are identified by sequential integers and that the correct number of substitution variables are provided in the array.
getSetForRelationship in interface AppServiceRemoterelOwner - The "owner" of the relationship name.
This is NOT the actual owner of the set to be returned.
It is needed so that this method can get the relationship Sql.relName - The relationship name.relColumn - Array of column names. This is used to configure the Sql with the proper datatype.
There should be the same number of elements in relColumns and relValues, and they should
match by index (relColumn[0] is the column name for relValue[0], etc.).
These must be valid attribute names for relOwner, OR be specified as
tbname.colname.relValue - Array of bind variables for the given relationship.userInfo - The userInfo making the request.MXExceptionjava.rmi.RemoteExceptiongetSetForRelationship(java.lang.String, java.lang.String, java.lang.String[], java.lang.String[], psdi.security.UserInfo)public MXLogger getServiceLogger()
public boolean checkSecurity(java.lang.String methodname,
UserInfo userInfo)
throws MXException,
java.rmi.RemoteException
This method is supplied so that web services can check security before invoking a method on an app service.
checkSecurity in interface AppServiceRemotemethodname - The name of the method to be checked.userInfo - The UserInfo whose privilege should be checked.MXExceptionjava.rmi.RemoteExceptionProfile.getAppOptionAuth(java.lang.String, java.lang.String, java.lang.String)