• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

question about distributable web applications

 
jeffrey z. lee
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which statements are true about distributable web applications?
1) There will be one instance of ServletContext in each VM
2) There will be only one instance of the default ServletContext in only one VM(the default ServletContext is one created for all servlets not deployed as part of an application are assigned)
3) All request that are part of a session must be handled by one VM at a time
 
Raj Paul
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Option 2 & 3 are true. and 1 would be true if the sentence contains non-default servlet instance
 
jeffrey z. lee
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
does question 3 is true mean that RequestDispatcher can not dispatch request to the servlet in other VM?
 
Raj Paul
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I dont think, a servlet can forward to another servlet located in another JVM.
 
Kyle Tang
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BTW, RequestDispatcher can not forward | include any url that is out of the current web-application, no matter what.
 
jeffrey z. lee
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank Raj Paul and Kyle Tang!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic