Hi, First, this error is not serious and can safely be ignored. But if you want avoid it, don't click other buttons until the action is done ;) Of course that's easier to say than to enforce. One way to enforce this is some basic JavaScript: set all form buttons to disabled when one is clicked, and have each button's action re-enable the other buttons when it's done. There are JavaScript examples online that do this, it's easy.
Yoav Shapira http://www.yoavshapira.com >-----Original Message----- >From: Daxin Zuo [mailto:[EMAIL PROTECTED] >Sent: Wednesday, November 10, 2004 4:17 PM >To: Tomcat Users List >Subject: Ask for the best way to handle an exception > >In a JSP page, there are buttons. clicking one will launch an action which >may read/write socket. In my program, all actions work well. But exception >caused in the circumstance: > I clicked a button. Before that action finished (in the middle of >read/write socket), immediately, I clicked another button. I get an error, >attached at the end of my email. Please forward your instruction. >Thanks. > >Nov 10, 2004 11:47:47 AM org.apache.jk.server.JkCoyoteHandler action >SEVERE: Error in action code >java.net.SocketException: Connection reset by peer: socket write error > at java.net.SocketOutputStream.socketWrite0(Native Method) > at >java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) > at java.net.SocketOutputStream.write(SocketOutputStream.java:136) > at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:489) > at >org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:697) > at >org.apache.jk.server.JkCoyoteHandler.action(JkCoyoteHandler.java:487) > at org.apache.coyote.Response.action(Response.java:226) > at org.apache.coyote.Response.finish(Response.java:348) > at >org.apache.coyote.tomcat5.OutputBuffer.close(OutputBuffer.java:328) > at >org.apache.coyote.tomcat5.CoyoteResponse.finishResponse(CoyoteResponse. java >: >497) > at >org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:209) > at >org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:339) > at >org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:415) > at >org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:716) > at >org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java :650 >) > at >org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:829) > at >org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPoo l.ja >v >a:688) > at java.lang.Thread.run(Thread.java:534) > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
