mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-13 20:12:14 +00:00
Merge branch 'JENKINS-32820' of https://github.com/atcarmo/jenkins into bug/JENKINS-32820
Conflicts: core/src/main/java/hudson/WebAppMain.java core/src/main/java/hudson/lifecycle/SolarisSMFLifecycle.java core/src/main/java/hudson/lifecycle/UnixLifecycle.java
This commit is contained in:
commit
579a88d6e7
4 files changed
+40
-7
No files matched your search
@@ -375,10 +375,16 @@ public class WebAppMain implements ServletContextListener {
|
||||
|
||||
public void contextDestroyed(ServletContextEvent event) {
|
||||
try (ACLContext old = ACL.as(ACL.SYSTEM)) {
|
||||
terminated = true;
|
||||
Jenkins instance = Jenkins.getInstanceOrNull();
|
||||
if (instance != null)
|
||||
instance.cleanUp();
|
||||
try {
|
||||
if (instance != null) {
|
||||
instance.cleanUp();
|
||||
}
|
||||
} catch (Exception e) {
|
||||
LOGGER.log(Level.SEVERE, "Failed to clean up. Restart will continue.", e);
|
||||
}
|
||||
|
||||
terminated = true;
|
||||
Thread t = initThread;
|
||||
if (t != null && t.isAlive()) {
|
||||
LOGGER.log(Level.INFO, "Shutting down a Jenkins instance that was still starting up", new Throwable("reason"));
|
||||
|
||||
Reference in new issue
Block a user