Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

webpage search and queues  RSS feed

 
camilla bat
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm using Tomcat and I'm not quite sure how my webpage handels scenarios as follows: The user clicks a search button which fires off a search to another system (via the service layer). There is no asynchronous call, just a normal synchronous call to the service layer. Now, I'm wandering what happens when the user clicks another time at the searchbutton before the last reponse was received. How is the webserver handling this?

Does it stop the first request that is waiting for the response? What if the first request is queued at the webserver?
Is the last request killed since there is already one waiting?

Anybody who knows?
Thanks.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try it out yourself.
It will stop the first request after getting the new.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!