INT-2485 Orderly Shutdown#403
Closed
garyrussell wants to merge 4 commits into
Closed
Conversation
Initial commit - @ManagedOperation on IMBE - can be invoked via JMX, <control-bus/>, or getting a reference to the IMBE from the application context. INT-2485 Updates After Review Comments (JIRA) * Shutdown Schedulers first, and wait for them * Add a force parameter, which overrides thread pool shutdown options * Shutdown Sources/Channels after all thread pools have stopped * Mark other components as OrderlyShutdownCapable (e.g. JMS/AMQP Listener containers) and shut them down first * Wait for remaining time to allow for quiescence Also * remove TimeUnit parameter (not JMX-friendly); time limit is now always milliseconds * If thread pools don't stop in time limit, force them down. INT-2485 Handle Self-Destruction Add shutdown-executor to IMBE. When the shutdown was called on a Spring-Managed thread, the shutdown was not clean because we timed out waiting for the current thread to terminate. After that, we force terminated other components. Now, by providing a dedicated Executor for the shutdown process, it is used for the shutdown instead of the current thread. This Executor is *not* shutdown. It is not necessary to provide an Executor if the stopActiveComponents() method is called on some other thread that is not involved in the shutdown. Also adds executor name to logs, when available. INT-2485 Polishing Fix MBean object name collision when running all tests. INT-2485 Enable TCP Shutdown Make TCP connection factories 'OrderlyShutdownCapable' so they are stopped before schedulers/executors in order for them to release any executor threads they are holding.
Didn't need DirectFieldAccessor - scheduler and executor have an accessor for the native ExecutorService. Copyrights
schemaLocation version.
Contributor
Author
|
Pushed PR Review Fixes; see last commit |
olegz
added a commit
to olegz/spring-integration
that referenced
this pull request
May 10, 2012
* INT-2485a: INT-2485 Orderly Shutdown
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://jira.springsource.org/browse/INT-2485
Initial commit - @ManagedOperation on IMBE
the IMBE from the application context.
INT-2485 Updates After Review Comments (JIRA)
Also
INT-2485 Handle Self-Destruction
Add shutdown-executor to IMBE.
When the shutdown was called on a Spring-Managed thread, the shutdown
was not clean because we timed out waiting for the current thread to
terminate. After that, we force terminated other components.
Now, by providing a dedicated Executor for the shutdown process, it
is used for the shutdown instead of the current thread. This Executor
is not shutdown.
It is not necessary to provide an Executor if the stopActiveComponents()
method is called on some other thread that is not involved in the
shutdown.
Also adds executor name to logs, when available.
INT-2485 Polishing
Fix MBean object name collision when running all tests.
INT-2485 Enable TCP Shutdown
Make TCP connection factories 'OrderlyShutdownCapable' so
they are stopped before schedulers/executors in order for
them to release any executor threads they are holding.