|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today! |
|
#1
|
|||
|
|||
|
I have made a servlet. If a remote user activates
the servlet from a web browser, then decides to click the Stop button on the web browser before processing has finished, the transfer is interrupted to the user's web browser, but the servlet continues to run until it has finished. Is there a way to pass the message that the transfer has been interrupted by the user to the servlet and get it to stop processing immediately? Thanks for any info, Maarten |
|
#2
|
|||
|
|||
|
I believe that when the browser has stopped listening for the HTTP responce (e.g. either through the stop button, browser shutdown or the obviosu one - browser crashing !) then whenever you try and write any data to the response PrintWriter then you get an IOException error (becasue the end of the pipe is closed).
(Now the techie disclaimer !) I've Never tried this - but I recall reading it in the O'Reilly Servlet "kettle" book (incase you have a copy handy) and a friend has adivsed me to do the same thing once (never did - found it didn''t matter much in my project before I tried it) |
![]() |
| Viewing: Dev Shed Forums > Programming Languages > Java Help > Servlet stopping while running |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|