org.objectweb.jonas.web
Interface AbsJWebContainerServiceImplMBean

All Known Implementing Classes:
AbsJWebContainerServiceImpl, CatalinaJWebContainerServiceWrapper, CatalinaJWebContainerServiceWrapper

public interface AbsJWebContainerServiceImplMBean

This interface provides a description for the web container management.

Author:
Ludovic Bert, Florent Benoit, Michel-Ange Anton (Contributor)

Method Summary
 java.util.List getAutoloadDirectories()
          Return the list of "autoload" directories for web applications.
 java.lang.Integer getCurrentNumberOfWars()
           
 java.util.List getDeployableWars()
          Return the list of installed web applications ready to deploy.
 java.util.List getDeployedWars()
          Return the list of all loaded web applications.
 java.util.List getInstalledWars()
          Return the list of installed web applications.
 java.lang.String getServerName()
          Gets the name of the server which is the web container
 java.lang.String getServerVersion()
          Gets the version of the server which is the web container
 java.util.Set getWarNames()
          This method is added temporarily.
 java.lang.String getWebappsDirectory()
          Return the WebApps directory.
 boolean isWarLoaded(java.lang.String fileName)
          Test if the specified filename is already deployed or not
 void registerWarMBean(java.lang.String fileName)
          Register a WAR, this method is used for the JMX Management.
 void unRegisterWarMBean(java.lang.String fileName)
          Unregister a WAR, this method is used for the JMX Management.
 

Method Detail

registerWarMBean

public void registerWarMBean(java.lang.String fileName)
                      throws java.rmi.RemoteException,
                             JWebContainerServiceException
Register a WAR, this method is used for the JMX Management.

Parameters:
fileName - the name of the war to deploy.
Throws:
java.rmi.RemoteException - if rmi call failed.
JWebContainerServiceException - if the registration of the WAR failed.

unRegisterWarMBean

public void unRegisterWarMBean(java.lang.String fileName)
                        throws java.rmi.RemoteException,
                               JWebContainerServiceException
Unregister a WAR, this method is used for the JMX Management.

Parameters:
fileName - the name of the war to undeploy.
Throws:
java.rmi.RemoteException - if rmi call failed.
JWebContainerServiceException - if the unregistration of the WAR failed.

getInstalledWars

public java.util.List getInstalledWars()
                                throws java.lang.Exception
Return the list of installed web applications. The WAR files or the directories with expanded web application are searched in JONAS_BASE/webapps and all webapps directories 'autoload'.

Returns:
The list of WAR files or the directories with expanded web application found
Throws:
java.lang.Exception - if the list can't be retrieved

getCurrentNumberOfWars

public java.lang.Integer getCurrentNumberOfWars()
Returns:
current number of wars deployed in the JOnAS server

getWarNames

public java.util.Set getWarNames()
This method is added temporarily. It will disapear when Wars will have their associated MBeans (when Wars will become manageable)

Returns:
the names of the wars currently deployed in the JOnAS server

isWarLoaded

public boolean isWarLoaded(java.lang.String fileName)
Test if the specified filename is already deployed or not

Parameters:
fileName - the name of the war file.
Returns:
true if the war is deployed, else false.

getServerName

public java.lang.String getServerName()
Gets the name of the server which is the web container

Returns:
the name of the server which is the web container

getServerVersion

public java.lang.String getServerVersion()
Gets the version of the server which is the web container

Returns:
the version of the server which is the web container

getDeployedWars

public java.util.List getDeployedWars()
Return the list of all loaded web applications.

Returns:
The list of deployed web applications

getDeployableWars

public java.util.List getDeployableWars()
                                 throws java.lang.Exception
Return the list of installed web applications ready to deploy.

Returns:
The list of deployable web applications
Throws:
java.lang.Exception - if the deployable wars can't be returned

getAutoloadDirectories

public java.util.List getAutoloadDirectories()
Return the list of "autoload" directories for web applications.

Returns:
The list of all "autoload" directories

getWebappsDirectory

public java.lang.String getWebappsDirectory()
Return the WebApps directory.

Returns:
The WebApps directory