org.idoox.webservice.server
Interface LifeCycleService


public interface LifeCycleService

This interface represents life cycle service, which manages instances of services for particular Web Service context.

It allows forced disposal of a particular service to set TTL of a service and registration of a life cycle controller, which is notified about services registration and unregistration, thus allowing the application to handle these events

Since:
1.0
Component:
Core

Method Summary
 void disposeServiceInstance(java.lang.Object instance)
          Deprecated. Forces deregistration of given service instance
 long getServiceInstanceTTL(java.lang.Object instance)
          Deprecated. Gets TTL of particular service instance.
 LifeCycleController registerLifeCycleController(LifeCycleController controller)
          Deprecated. Registers LifeCycleController for this Web Service context
 void setServiceInstanceTTL(java.lang.Object instance, long ttl)
          Deprecated. Sets TTL of particular service instance.
 

Method Detail

disposeServiceInstance

public void disposeServiceInstance(java.lang.Object instance)
Deprecated. 
Forces deregistration of given service instance

Parameters:
instance - the service instance to be unregistered

setServiceInstanceTTL

public void setServiceInstanceTTL(java.lang.Object instance,
                                  long ttl)
Deprecated. 
Sets TTL of particular service instance.

Use value -1 to set TTL to indefinite.

Parameters:
instance - the service instance to be set TTL for
ttl - TTL value to be set

getServiceInstanceTTL

public long getServiceInstanceTTL(java.lang.Object instance)
Deprecated. 
Gets TTL of particular service instance.

Parameters:
instance - the service instance to be set TTL for
Returns:
ttl TTL value to be set

registerLifeCycleController

public LifeCycleController registerLifeCycleController(LifeCycleController controller)
Deprecated. 
Registers LifeCycleController for this Web Service context

Parameters:
controller - LifeCycleController interface implementation to be associated with this LifeCycleService
Returns:
Previous registered life cycle controller or null if none registered