Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

session timeout

 
Harish Yerneni
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A session whose timeout period has been set to -1 will never expire.(Reference page 271, Q3 option A is given correct)

Can someone explain?

My understanding is that if you put 0 or any negative number in setmaxinactiveInterval(0 or -1)...the session dies immediately.
 
Osama Hasan
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
According to me, specifying a negative value and not 0 for the setMaxInactiveInterval() method means that the session would NEVER expire. Specifying 0, will immediately expunge the session. I tried it out and it worked as expected.
 
Harish Yerneni
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, Osama.

That helps!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic