Reputation: 225
Does it make sense do define session-timeout with restful web services like jax-rs? For what I know the rest is stateless (or should be stateless) so what the point of storing a session? If I don't define the session-timeout in the configuration file web.xml for how long session will be stored in servlet container?
Upvotes: 1
Views: 1575
Reputation: 10154
Basically REST should be stateless and you should not create a session for the rest calls.
If you don't specify the session timeout, it uses the default one specified by the container. In tomcat the default is 30 minutes.
Upvotes: 2