How to override session time out in spring web application
<p>I am writing an application in Spring to be deployed to a Cloudfoundry container and want to override the default tomcat session timeout value from the Java buildpack. What are the options available to me if I want it to be a configurable value outside my code? i.e. avoid the use of <code>HttpSession.setMaxInactiveInterval(int)</code>.</p>

<ol>
<li>set-env JAVA_OPTS -Dserver.session.timeout=30</li>
<li>some way in application properties?</li>
</ol>