Currently start() and stop() methods comes from the Plugin interface. It can be a good idea to move then to a new Lifecycle interface. The AbstractPlugin should extends this new interface for compatibility.
It will allow application developers to easily start/stop resources without creating a Plugin. Lifecycle implementations can be scanned during the init phase so there will be no need for ServiceLoader here.
Currently
start()andstop()methods comes from thePlugininterface. It can be a good idea to move then to a newLifecycleinterface. TheAbstractPluginshould extends this new interface for compatibility.It will allow application developers to easily start/stop resources without creating a
Plugin.Lifecycleimplementations can be scanned during the init phase so there will be no need forServiceLoaderhere.