org.objectweb.jonas.ear
Interface EarService

All Superinterfaces:
Service
All Known Implementing Classes:
JOnASEARService

public interface EarService
extends Service

JOnAS EAR Service interface. This interface provides a description of an EAR service.

Author:
Ludovic Bert, Florent Benoit

Method Summary
 String deployEar(Context ctx)
          Deploy an EAR file with sending JAR file to the EJB container and WAR file to the WEB container.
 String deployEar(String fileName)
          Deploy an EAR, used by management applications via J2EEServer managed object.
 Boolean isEarDeployed(String fileName)
          Test if the specified filename is already deployed or not.
 boolean isEarDeployedByUnpackName(String unpackName)
          Test if the specified unpack name is already deployed or not.
 void unDeployEar(Context ctx)
          Undeploy an EAR by sending the request to the EJB container and to the WEB container.
 void unDeployEar(String fileName)
          Undeploy an EAR, used by management applications via J2EEServer managed object.
 
Methods inherited from interface org.objectweb.jonas.service.Service
getName, init, isStarted, setName, start, stop
 

Method Detail

deployEar

String deployEar(Context ctx)
                 throws EarServiceException
Deploy an EAR file with sending JAR file to the EJB container and WAR file to the WEB container.

Parameters:
ctx - the context which contains the configuration in order to deploy an EAR.
Returns:
The ObjectName of the J2EE Application MBean associated to the deployed EAR
Throws:
EarServiceException - if the deployment of the EAR failed.

unDeployEar

void unDeployEar(Context ctx)
                 throws EarServiceException
Undeploy an EAR by sending the request to the EJB container and to the WEB container.

Parameters:
ctx - the context which contains the configuration in order to undeploy an EAR.
Throws:
EarServiceException - if the undeployment of the EAR failed.

deployEar

String deployEar(String fileName)
                 throws Exception
Deploy an EAR, used by management applications via J2EEServer managed object.

Parameters:
fileName - the fileName of the ear which must be be deployed.
Returns:
The ObjectName of the MBean associated to the deployed J2EE Application
Throws:
Exception - if the deployment of the EAR failed.

isEarDeployed

Boolean isEarDeployed(String fileName)
Test if the specified filename is already deployed or not.

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

isEarDeployedByUnpackName

boolean isEarDeployedByUnpackName(String unpackName)
Test if the specified unpack name is already deployed or not. This method is defined in the EarService interface.

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

unDeployEar

void unDeployEar(String fileName)
                 throws Exception
Undeploy an EAR, used by management applications via J2EEServer managed object.

Parameters:
fileName - the fileName of the ear which must be be undeployed.
Throws:
Exception - if the undeployment of the EAR failed.


Copyright © 2007 OW2 Consortium. All Rights Reserved.