• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HFSJ Mock question on Session timeout

 
M Jairam
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
On Page 273, the following is the question:

Which statements about HttpSession objects are true?
A....
B....
C. A session will become invalid after a timeout period defined by the servlet container.
D....

The book says "C" is correct. I think it is wrong. The session only becomes invalid after a timeout period defined by the container only if its "inactive time" exceeds the timeout period.

Is my observation correct or am I misreading. Please let me know.

Thanks.
 
Rajesh Vijaya
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Session can become invalid if the
<session-timeout> configured in DD expires...refer PAGE 243 in HFSJ...


Rajesh

SCJP1.4 SCWCD1.4 (Preparing..)
 
fred rosenberger
lowercase baba
Bartender
Posts: 12263
36
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rajesh,

glad you're here helping around the 'ranch. However, you're name does not conform to our naming policy. Briefly, it requires a real sounding first name, a space, and last name. Obviously ficticious names are also not allowed.

Would you be so kind as to visit here and update your name?

Thanks, and we'll see you 'round the ranch!!!
 
Albin Joseph
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by M Jairam:
On Page 273, the following is the question:

The session only becomes invalid after a timeout period defined by the container only if its "inactive time" exceeds the timeout period.

Is my observation correct or am I misreading. Please let me know.

Thanks.


I think you are correct. If the session is active , the time out will never happen
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic