Jenkins uses Jetty and the default timeout for Jetty is 30 minutes . It does not depend on the authentication settings - I use Active Directory, but still this option affects timeouts.
You can override the timeout by passing the argument --sessionTimeout=<minutes> to the Jenkins init script or -DsessionTimeout=<minutes> to the .war file. For example:
Alternatively, you can edit Jenkins <jenkinsHome>/.jenkins/war/WEB-INF/web.xml and add it explicitly:
<session-config> <session-timeout>60</session-timeout> </session-config>
According to Oracle docs, you can set this value to 0 to completely disable timeouts.
To find out the current timeout value, you can use the Groovy console provided in Jenkins:
import org.kohsuke.stapler.Stapler; Stapler.getCurrentRequest().getSession().getMaxInactiveInterval() / 60
In my instance, this shows Result: 30 .
Wilfred Hughes Aug 04 '15 at 12:57 2015-08-04 12:57
source share