File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Bunkhouse Porch and the fly likes Problem in Implementing the example of headfirst servlets and jsp in netbeans Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Books » Bunkhouse Porch
Reply locked New topic
Author

Problem in Implementing the example of headfirst servlets and jsp in netbeans

Rachit Kumar Saxena
Ranch Hand

Joined: Dec 24, 2011
Posts: 50
I was trying an example of the example of above book on page 190(example is given as newservlet.jpeg(please open it with any text editor as it is not a valid .jpeg file)).The first time when the servlet is run though the output is 22 and 42,but as the context attributes arent thread safe,the second time when I run the servlet the result should have been affected(as pointed out in the book),but i see the same output.Why do i see the same output each time?


[newservlet.jpeg]

Palak Mathur
Ranch Hand

Joined: Jan 29, 2007
Posts: 313

Rachit Kumar Saxena wrote:I was trying an example of the example of above book on page 190(example is given as newservlet.jpeg(please open it with any text editor as it is not a valid .jpeg file)).The first time when the servlet is run though the output is 22 and 42,but as the context attributes arent thread safe,the second time when I run the servlet the result should have been affected(as pointed out in the book),but i see the same output.Why do i see the same output each time?


This is not the right forum to ask questions like this one.

Moderators,

Please move this to the appropriate forum.


Palak Mathur | My Blog | TechJaunt | What is JavaRanch? | List of All FAQs
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 9317
    
109

Actually, Rachit already has created a duplicate thread here http://www.coderanch.com/t/583965/vc/Implementing-example-headfirst-servlets-jsp. Locking this one.

[My Blog] [JavaRanch Journal]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem in Implementing the example of headfirst servlets and jsp in netbeans
 
Similar Threads
Servlet Life Cycle Doubts
Problem in Implementing the example of headfirst servlets and jsp in netbeans
automatic refreshing
Change Timezone from GMT to EST, the best way to accomplish?
Jrun problem