Package io.joynr.jeeintegration.api
Interface JoynrShutdownService
-
- All Known Implementing Classes:
JoynrShutdownServiceBean
public interface JoynrShutdownServiceInject this service into your application in order to programmatically control shutdown of joynr runtime, for example if you want to perform clean-up operations before the application quits. You can optionally first callprepareForShutdown()in order to give joynr a chance to finish processing messages and stop receiving any more incoming messages. This call will block until either the preparation is complete, or a timeout occurs. See the joynr Java settings guide for details on how to configure the timeout. Once you've made the prepareForShutdown call, you will not be able to send any more requests which require state to be held by joynr (e.g. method calls via a Sync interface). You will be able to still perform calls for stateless async and fire-and-forget methods, as these do not require any state to be held by the runtime. Thereafter you can callshutdown()in order to tell the joynr runtime to close and free all resources and perform any necessary clean-up on its part.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidprepareForShutdown()Call this method to cause the joynr runtime to prepare for shutdown and perform initial clean-up.voidshutdown()This call will completely shut down the joynr runtime and free up any and all resources it holds.
-
-
-
Method Detail
-
prepareForShutdown
void prepareForShutdown()
Call this method to cause the joynr runtime to prepare for shutdown and perform initial clean-up. This method blocks until completion or it times out. After calling this method you can only make requests via joynr which to not require state to be held (e.g. stateless async or fire-and-forget).
-
shutdown
void shutdown()
This call will completely shut down the joynr runtime and free up any and all resources it holds. You cannot perform any further joynr operations after this method has been called.
-
-