• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

isThreadSafe problem in JSP

 
Michael Santosa
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I feel a little bit confuse about isThreadSafe attribute in JSP page directive,
isThreadSafe = "true" then JSP is not implementing SingleThreadModel
and if
isThreadSafe = "false" then JSP is implementing
SingleThreadModel,
I think in semantic meaning by implementing SingleThreadModel then it should be ThreadSafe,
because there will be many instances of that servlet.. so why SUN make the attribute isThreadSafe = "false" then it will implement SingleThreadModel ?? is there any reason behind this ?
Thank you in advance
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is there any reason behind this ?

Yep, just to confuse you.
Really what it is asking you is. Is the JSP file you created ThreadSafe, if it is, I will not make the servlet, that I am about to create for you, implement SingleThreadModel..
So by stating true, you state yes, I made this JSP threadsafe so you don't have to worry about it.
By stating False you are saying, hey I did nothing to makethis threadsafe, please do it for me.
Hope that helps make it seem less confusing.
Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic