Writing an ObjectGridPlugin plug-in
An ObjectGridPlugin is an optional mix-in interface that you can use to provide extended life cycle management events to all other ObjectGrid plug-ins.
About this task
Any ObjectGrid plug-in that implements the ObjectGridPlugin receives the extended set of life cycle events, and can provide more control, which you can use to set up or remove resources. In a container for a partitioned data grid, there will be one ObjectGrid instance (the plugin owner) for each partition managed by the container.When individual partitions are removed, the resources that are used by that ObjectGrid instance must also be removed. Therefore, you might need to close or end a resource, such as an open configuration file or a running thread that is managed by a plug-in, when the owning partition for that resource is removed.
The ObjectGridPlugin interface provides methods to set or modify the state of the plug-in, as well as methods to introspect the current state of the plug-in. All methods must be implemented correctly, and the WebSphere® eXtreme Scale runtime environment verifies the method behavior under certain circumstances. For example, after calling the initialize() method, the eXtreme Scale runtime environment calls the isInitialized() method to ensure that the method successfully completed the appropriate initialization.