it.imolinfo.jbi4ejb.jbi.component
Class Jbi4EjbSUManager

java.lang.Object
  extended by it.imolinfo.jbi4ejb.jbi.component.runtime.DefaultServiceUnitManager
      extended by it.imolinfo.jbi4ejb.jbi.component.Jbi4EjbSUManager
All Implemented Interfaces:
javax.jbi.component.ServiceUnitManager

public class Jbi4EjbSUManager
extends DefaultServiceUnitManager

Jbi4Ejb Service Unit Manager. Redefines: deploy/implement (no init).

Author:
Marco Piraccini
See Also:
for more details of the generated code.

Constructor Summary
Jbi4EjbSUManager(ComponentRuntime ctx)
          Constructor that takes the ComponentRuntime parameter.
 
Method Summary
 void deactivateEndpoint(Jbi4EjbEndpoint endpoint)
          Activate the endpoint array.
 java.lang.String deploy(java.lang.String suName, java.lang.String suZipPath)
          Deploy a Service Unit to the component.
 java.util.List<Jbi4EjbEndpoint> getDeployedEndpoints()
          Gets the deployed endpoints.
 Jbi4EjbLifeCycle getLifeCycle()
          Gets the life cycle.
 Jbi4EjbEndpoint getStartedEndpoint(javax.jbi.servicedesc.ServiceEndpoint endpoint)
          Gets the started endpoint from the ServiceEndpoint description.
 void init(java.lang.String serviceUnitName, java.lang.String serviceUnitRootPath)
          Service unit init, process the Endpoint deploy.
static javax.wsdl.Definition readWsdl(java.io.File f)
          Reads a Definition from a File.
 void setLifeCycle(Jbi4EjbLifeCycle lifeCycle)
          Sets the life cycle.
 void shutDown(java.lang.String serviceUnitName)
          Service unit shutdown, removes the deployed endpoint.
 void start(java.lang.String serviceUnitName)
          Start the deployed service unit.
 void stop(java.lang.String serviceUnitName)
          Stop the service unit.
 java.lang.String undeploy(java.lang.String serviceUnitName, java.lang.String suZipPath)
          Undeploy a service unit from the component.
 
Methods inherited from class it.imolinfo.jbi4ejb.jbi.component.runtime.DefaultServiceUnitManager
createComponentTaskResultXML
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Jbi4EjbSUManager

public Jbi4EjbSUManager(ComponentRuntime ctx)
Constructor that takes the ComponentRuntime parameter.

Parameters:
ctx - the component runtime context
Method Detail

deploy

public java.lang.String deploy(java.lang.String suName,
                               java.lang.String suZipPath)
                        throws javax.jbi.management.DeploymentException
Deploy a Service Unit to the component.

Specified by:
deploy in interface javax.jbi.component.ServiceUnitManager
Overrides:
deploy in class DefaultServiceUnitManager
Parameters:
suName - the service unit name
suZipPath - the service unit unzip path
Returns:
the xml message string
Throws:
javax.jbi.management.DeploymentException - if some deploy problem occurs
See Also:
ServiceUnitManager.deploy(String, String);

start

public void start(java.lang.String serviceUnitName)
           throws javax.jbi.management.DeploymentException
Start the deployed service unit.

Specified by:
start in interface javax.jbi.component.ServiceUnitManager
Overrides:
start in class DefaultServiceUnitManager
Parameters:
serviceUnitName - the service unit name
Throws:
javax.jbi.management.DeploymentException - if some problem occurs
See Also:
ServiceUnitManager.start(String);

undeploy

public java.lang.String undeploy(java.lang.String serviceUnitName,
                                 java.lang.String suZipPath)
                          throws javax.jbi.management.DeploymentException
Undeploy a service unit from the component.

Specified by:
undeploy in interface javax.jbi.component.ServiceUnitManager
Overrides:
undeploy in class DefaultServiceUnitManager
Parameters:
suZipPath - the service unit unzip path
serviceUnitName - the service unit name
Returns:
the xml result message
Throws:
javax.jbi.management.DeploymentException - if some problem occurs
See Also:
ServiceUnitManager.undeploy(String, String);

stop

public void stop(java.lang.String serviceUnitName)
          throws javax.jbi.management.DeploymentException
Stop the service unit.

Specified by:
stop in interface javax.jbi.component.ServiceUnitManager
Overrides:
stop in class DefaultServiceUnitManager
Parameters:
serviceUnitName - the service unit name
Throws:
javax.jbi.management.DeploymentException - if some problem occurs
See Also:
ServiceUnitManager.stop(String);

init

public void init(java.lang.String serviceUnitName,
                 java.lang.String serviceUnitRootPath)
          throws javax.jbi.management.DeploymentException
Service unit init, process the Endpoint deploy.

Specified by:
init in interface javax.jbi.component.ServiceUnitManager
Overrides:
init in class DefaultServiceUnitManager
Parameters:
serviceUnitName - the service unit name
serviceUnitRootPath - the service unit root path
Throws:
javax.jbi.management.DeploymentException - if some problem occurs
See Also:
ServiceUnitManager.init(String, String);

shutDown

public void shutDown(java.lang.String serviceUnitName)
              throws javax.jbi.management.DeploymentException
Service unit shutdown, removes the deployed endpoint.

Specified by:
shutDown in interface javax.jbi.component.ServiceUnitManager
Overrides:
shutDown in class DefaultServiceUnitManager
Parameters:
serviceUnitName - the service unit name
Throws:
javax.jbi.management.DeploymentException - if some problem occurs
See Also:
javax.jbi.component.ServiceUnitManager#shutdown(String);

getStartedEndpoint

public Jbi4EjbEndpoint getStartedEndpoint(javax.jbi.servicedesc.ServiceEndpoint endpoint)
Gets the started endpoint from the ServiceEndpoint description.

Parameters:
endpoint - the Jbi4EjbEndpoint
Returns:
the endpoint if found, null otherwise

deactivateEndpoint

public void deactivateEndpoint(Jbi4EjbEndpoint endpoint)
                        throws Jbi4EjbDeployException
Activate the endpoint array.

Parameters:
endpoint - the endpoints to deactivate
Throws:
Jbi4EjbDeployException - if some deployment problem occurs

readWsdl

public static javax.wsdl.Definition readWsdl(java.io.File f)
                                      throws javax.wsdl.WSDLException
Reads a Definition from a File.

Parameters:
f - the file to read
Returns:
the WSDL definition
Throws:
javax.wsdl.WSDLException - if there are problem in reading the WSDL

getLifeCycle

public Jbi4EjbLifeCycle getLifeCycle()
Gets the life cycle.

Returns:
the life cycle

setLifeCycle

public void setLifeCycle(Jbi4EjbLifeCycle lifeCycle)
Sets the life cycle.

Parameters:
lifeCycle - the new life cycle

getDeployedEndpoints

public java.util.List<Jbi4EjbEndpoint> getDeployedEndpoints()
Gets the deployed endpoints.

Returns:
the deployed endpoints


Copyright © 2007-2008 Imola Informatica. All Rights Reserved.