@ RequirePOST public void doCancelRestart ( StaplerResponse response ) throws IOException , ServletException { synchronized ( jobs ) { for ( UpdateCenterJob job : jobs ) { if ( job instanceof RestartJenkinsJob ) { if ( ( ( RestartJenkinsJob ) job ) . cancel ( ) ) { LOGGER . info ( "Scheduled Jenkins reboot unscheduled" ) ; } } } } response . sendRedirect2 ( "." ) ; }
Cancel all scheduled jenkins restarts