Package com.tangosol.application
Interface LifecycleListener
-
- All Known Implementing Classes:
GrpcServerController.Listener
public interface LifecycleListenerA Coherence application typically includes a cache configuration file with cache and clustered service definitions. This interface defines lifecycle callbacks that are invoked before and after the creation and destruction of these services.Implementations of this interface are typically declared in a Coherence application deployment descriptor in a GAR (Grid Archive) file. The instantiation occurs in
ContainerAdapter, which is the application server integration layer.- Since:
- Coherence 12.1.2
- Author:
- cf 2011.05.24
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidpostStart(Context ctx)Called after the application is started.voidpostStop(Context ctx)Called after the application is stopped.voidpreStart(Context ctx)Called before the application is activated.voidpreStop(Context ctx)Called before the application stops its services and disposes of its resources.
-
-
-
Method Detail
-
preStart
void preStart(Context ctx)
Called before the application is activated. In general this occurs before services in a cache configuration file are started thus allowing for pre service setup.The
Contextcontains the context of the application allowing for a custom application to create custom services and/or a customCacheFactoryBuilderimplementation.- Parameters:
ctx- theContextfor the application
-
postStart
void postStart(Context ctx)
Called after the application is started. At this point, services marked with<autostart>will have been started. These services (and caches) can be accessed viaContext.getConfigurableCacheFactory().- Parameters:
ctx- theContextfor the application
-
preStop
void preStop(Context ctx)
Called before the application stops its services and disposes of its resources.- Parameters:
ctx- theContextfor the application
-
-