Steps 1: Write a singleton class which willl implement interface -
weblogic.cluster.singleton.SingletonService public void activate()-
public void deactivate()
This method should obtain any system resources and start any services required for the singleton service to begin processing requests. This method is called in the following cases:
Steps 2: make a jar and copy to App-Inf/lib folder so that it is picked during application intialisation.
Step 3:Add the following entry to the weblogic-application.xml descriptor file. <weblogic-application> ... <singleton-service> <class-name>mypackage.MySingletonServiceImpl</class-name> <name>Appscoped_Singleton_Service</name> </singleton-service> ... </weblogic-application>
Resource --
http://download.oracle.com/docs/cd/E11035_01/wls100/cluster/service_migration.html#wp1051471
No comments:
Post a Comment