This week's book giveaway is in the Performance forum.
We're giving away four copies of The Java Performance Companion and have Charlie Hunt, Monica Beckwith, Poonam Parhar, & Bengt Rutisson on-line!
See this thread for details.
Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

double submit / how many requests and threads?

 
Tapio Niemela
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

after some googling I could not find satisfactory answer..

What happens when user double submits (double clicks "Submit" or similar) form to servlet? Will/could it create 2 httprequests and 2 threads? Or one httprequest and 2 threads? Or something else?

Please help
 
Paul Clapham
Sheriff
Posts: 21149
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's not that complicated. Each time the user clicks on that "Submit" button the browser creates an HTTP request. That's all there is to it.
 
Tapio Niemela
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul Clapham wrote:It's not that complicated. Each time the user clicks on that "Submit" button the browser creates an HTTP request. That's all there is to it.


Thanks Paul, so I assume two threads are also created; one for each request
 
Paul Clapham
Sheriff
Posts: 21149
32
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course. The server always uses a separate thread for each request.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic