|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.rmi.PortableRemoteObject org.objectweb.jonas.adm.Adm
public class Adm
This class implements a remote interface used for administering the server.
Field Summary | |
---|---|
static java.lang.String |
ADMNAME_SUFFIX
|
static int |
NOT_READY
|
static int |
READY
|
static int |
SLEEP_DELAY
Sleep before exit of JVM |
static int |
STOPPED
|
Fields inherited from interface org.objectweb.jonas.adm.AdmInterface |
---|
STATUS_ALL, STATUS_RUNNING, STATUS_STOPPED, TYPE_CAR, TYPE_EAR, TYPE_EJB, TYPE_RAR, TYPE_WAR |
Constructor Summary | |
---|---|
Adm(JProp jp)
Adm constructor |
Method Summary | |
---|---|
void |
addBeans(java.lang.String fileName)
Create a container and load beans in it |
void |
addEar(java.lang.String fileName)
Deploy a given ear file with the help of the ear service. |
void |
addRar(java.lang.String fileName)
Deploy a given rar file with the help of the resource service. |
void |
addWar(java.lang.String fileName)
Deploy a given war file with the help of the web container service. |
java.lang.String |
deployFile(int type,
byte[] bfile,
java.lang.String filename)
Deploy file (GenIC), needed for Ishmael to work. |
void |
deployFileOn(java.lang.String filename,
java.lang.String[] target)
Deploy file on another server or a cluster. |
java.lang.String |
dumpCustom()
|
int |
getServerState()
To test if the server is ready |
java.lang.String |
getTopicLevel(java.lang.String topic)
get Topic Level |
java.lang.String[] |
getTopics()
get Topics. |
boolean |
isEarLoaded(java.lang.String fileName)
Test if the specified filename is already deployed or not |
boolean |
isEJBContainer()
To test if the server is an EJB container |
boolean |
isLoaded(java.lang.String fileName)
returns true if beans are already loaded in server. |
boolean |
isRarLoaded(java.lang.String fileName)
Test if the specified filename is already deployed or not |
boolean |
isWarLoaded(java.lang.String fileName)
Test if the specified filename is already deployed or not |
void |
killServer()
Stop the Server and stop the JVM |
java.lang.String[] |
listBeans()
List beans of all JOnAS containers |
java.util.Vector |
listContext()
List JNDI context |
java.util.Properties |
listEnv()
List Environment (configuration properties provided by the configuration file). |
java.util.List |
listModules(int type,
int state)
List modules, needed for Ishmael to work. |
void |
removeBeans(java.lang.String fileName)
Remove the container identified by fileName and remove all beans in it |
void |
removeEar(java.lang.String fileName)
UnDeploy a given ear file with the help of the ear service. |
void |
removeRar(java.lang.String fileName)
UnDeploy a given rar file with the help of the resource service. |
void |
removeWar(java.lang.String fileName)
UnDeploy a given war file with the help of the web container service. |
void |
runGC()
run the garbage collector |
void |
serverReady(boolean isEJB)
server is ready |
void |
setTopicLevel(java.lang.String topic,
java.lang.String l)
set Topic Level |
void |
setTransactionTimeout(int timeout)
set the default value for transaction timeout |
void |
startRemoteServers(java.lang.String[] target)
Start remote servers or clusters |
void |
stopRemoteServers(java.lang.String[] target)
Stop remote servers or clusters |
void |
stopServer()
Stop the Server without stopping the JVM |
void |
syncAllEntities(boolean passivate)
sync all entity instances outside transactions |
void |
undeployFile(java.lang.String filename)
Physically remove the module from the server |
Methods inherited from class javax.rmi.PortableRemoteObject |
---|
connect, exportObject, narrow, toStub, unexportObject |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ADMNAME_SUFFIX
public static final int NOT_READY
public static final int READY
public static final int STOPPED
public static final int SLEEP_DELAY
Constructor Detail |
---|
public Adm(JProp jp) throws java.rmi.RemoteException, javax.naming.NamingException, ServiceException, java.lang.Exception
java.rmi.RemoteException
- if problem
javax.naming.NamingException
ServiceException
java.lang.Exception
Method Detail |
---|
public java.lang.String[] getTopics() throws java.rmi.RemoteException
getTopics
in interface AdmInterface
java.rmi.RemoteException
public java.lang.String getTopicLevel(java.lang.String topic) throws java.rmi.RemoteException
getTopicLevel
in interface AdmInterface
java.rmi.RemoteException
public void setTopicLevel(java.lang.String topic, java.lang.String l) throws java.rmi.RemoteException
setTopicLevel
in interface AdmInterface
java.rmi.RemoteException
public void addBeans(java.lang.String fileName) throws java.rmi.RemoteException
addBeans
in interface AdmInterface
fileName
- name of the ejb-jar or xml file
java.rmi.RemoteException
public void addEar(java.lang.String fileName) throws java.rmi.RemoteException, EarServiceException
addEar
in interface AdmInterface
fileName
- the name of the ear file.
java.rmi.RemoteException
- if rmi call failed.
EarServiceException
- if the deployment failed.public boolean isEarLoaded(java.lang.String fileName) throws java.rmi.RemoteException, EarServiceException
isEarLoaded
in interface AdmInterface
fileName
- the name of the ear file.
java.rmi.RemoteException
- if rmi call failed.
EarServiceException
public void addRar(java.lang.String fileName) throws java.rmi.RemoteException, ResourceServiceException
addRar
in interface AdmInterface
fileName
- the name of the rar file.
java.rmi.RemoteException
- if rmi call failed.
ResourceServiceException
- if the deployment failed.public boolean isRarLoaded(java.lang.String fileName) throws java.rmi.RemoteException, ResourceServiceException
isRarLoaded
in interface AdmInterface
fileName
- the name of the rar file.
java.rmi.RemoteException
- if rmi call failed.
ResourceServiceException
- if unable to get resource servicepublic void addWar(java.lang.String fileName) throws java.rmi.RemoteException, JWebContainerServiceException
addWar
in interface AdmInterface
fileName
- the name of the war file.
java.rmi.RemoteException
- if rmi call failed.
JWebContainerServiceException
- if the deployment failed.public boolean isWarLoaded(java.lang.String fileName) throws java.rmi.RemoteException, JWebContainerServiceException
isWarLoaded
in interface AdmInterface
fileName
- the name of the war file.
java.rmi.RemoteException
- if rmi call failed.
JWebContainerServiceException
public void removeEar(java.lang.String fileName) throws java.rmi.RemoteException, EarServiceException
removeEar
in interface AdmInterface
fileName
- the name of the ear file.
java.rmi.RemoteException
- if rmi call failed.
EarServiceException
- if the undeployment failed.public void removeRar(java.lang.String fileName) throws java.rmi.RemoteException, ResourceServiceException
removeRar
in interface AdmInterface
fileName
- the name of the rar file.
java.rmi.RemoteException
- if rmi call failed.
ResourceServiceException
- if the undeployment failed.public void removeWar(java.lang.String fileName) throws java.rmi.RemoteException, JWebContainerServiceException
removeWar
in interface AdmInterface
fileName
- the name of the war file.
java.rmi.RemoteException
- if rmi call failed.
JWebContainerServiceException
- if the undeployment failed.public void removeBeans(java.lang.String fileName) throws java.rmi.RemoteException
removeBeans
in interface AdmInterface
fileName
- name of the ejb-jar or xml file
java.rmi.RemoteException
public boolean isLoaded(java.lang.String fileName) throws java.rmi.RemoteException
isLoaded
in interface AdmInterface
fileName
- name of the ejb-jar or xml file
java.rmi.RemoteException
public java.lang.String dumpCustom() throws java.rmi.RemoteException
dumpCustom
in interface AdmInterface
java.rmi.RemoteException
public java.lang.String[] listBeans() throws java.rmi.RemoteException
listBeans
in interface AdmInterface
java.rmi.RemoteException
public java.util.Vector listContext() throws java.rmi.RemoteException
listContext
in interface AdmInterface
java.rmi.RemoteException
public java.util.Properties listEnv()
listEnv
in interface AdmInterface
public void stopServer() throws java.rmi.RemoteException
stopServer
in interface AdmInterface
java.rmi.RemoteException
public void killServer() throws java.rmi.RemoteException
killServer
in interface AdmInterface
java.rmi.RemoteException
public int getServerState() throws java.rmi.RemoteException
getServerState
in interface AdmInterface
java.rmi.RemoteException
public boolean isEJBContainer() throws java.rmi.RemoteException
isEJBContainer
in interface AdmInterface
java.rmi.RemoteException
public void setTransactionTimeout(int timeout) throws java.rmi.RemoteException
setTransactionTimeout
in interface AdmInterface
java.rmi.RemoteException
public void runGC() throws java.rmi.RemoteException
runGC
in interface AdmInterface
java.rmi.RemoteException
public void syncAllEntities(boolean passivate) throws java.rmi.RemoteException
syncAllEntities
in interface AdmInterface
passivate
- passivate instances after synchronization.
java.rmi.RemoteException
public void serverReady(boolean isEJB)
public java.lang.String deployFile(int type, byte[] bfile, java.lang.String filename) throws java.rmi.RemoteException, EarServiceException, JWebContainerServiceException
deployFile
in interface AdmInterface
type
- type of the file (EJB, WAR, EAR, RAR, CAR)bfile
- filename
- basename of the file to be deployed
java.rmi.RemoteException
EarServiceException
ResourceServiceException
JWebContainerServiceException
public java.util.List listModules(int type, int state) throws java.rmi.RemoteException
listModules
in interface AdmInterface
type
- type of the file (EJB, WAR, EAR, RAR, CAR)state
- status of the modules to be returned (RUNNING, STOPPED, ALL)
java.rmi.RemoteException
public void undeployFile(java.lang.String filename) throws java.rmi.RemoteException
undeployFile
in interface AdmInterface
filename
- the filename of the module to be removed
java.rmi.RemoteException
public void startRemoteServers(java.lang.String[] target) throws java.rmi.RemoteException
startRemoteServers
in interface AdmInterface
target
- List of clusters or servers to start
java.rmi.RemoteException
public void stopRemoteServers(java.lang.String[] target) throws java.rmi.RemoteException
stopRemoteServers
in interface AdmInterface
target
- List of clusters or servers to stop
java.rmi.RemoteException
public void deployFileOn(java.lang.String filename, java.lang.String[] target) throws java.rmi.RemoteException
deployFileOn
in interface AdmInterface
filename
- Name of the filetarget
- List of clusters or servers where to deploy the file.
java.rmi.RemoteException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |