• Post Reply Bookmark Topic Watch Topic
  • New Topic

If we declare a page isThreadSafe="false" then how the page will act?  RSS feed

 
RaviNada Kiran
Ranch Hand
Posts: 528
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read that the default value of isThreadSafe is true, and when we specify it as false will it be implementing SingleThreadModel ??
 
Nitesh Kant
Bartender
Posts: 1638
IntelliJ IDE Java MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
CarefullyChooseOneForum while posting. This has got nothing to do with Performance i feel.
Moving to JSP forum.
 
Amit Ghorpade
Bartender
Posts: 2856
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
RaviNada Kiran wrote:I read that the default value of isThreadSafe is true, and when we specify it as false will it be implementing SingleThreadModel ??

Yes its true. The container will send only a single request to the generated servlet when you set the attribute to false. But setting it to false is not at all recommended since its not guaranteed that page is actually thread safe (thread safety lies in design) and the STM is already deprecated.
For more info, take a look at this link
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
RaviNada Kiran wrote:when we specify it as false will it be implementing SingleThreadModel ??


yes. but it is deprecated
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!