this happens with any servlet...

I tried this on my machine and it doesn't really happen. I think this is because my connection to
the server is so fast that I dont have enough time to make a double click. But I've got a coworker that is doing the tests. He has a slower connection and if he just make more than one click on any button on a form..the server crash down.


For example: I have a servlet that calls a function that inserts(create) something in a database.
When the user makes double click on "Create" instead of just one click..the server try and try to
make the insert..and at the end..just gets blank.


other times it shows a database error of "duplicated key". I understand this is because the server
try to process the two request..but I need to control this..and only permit one process.


likewise..we also have a little similar problem with frames..because the frame called two servlets
at the same time..and we had to make a delay in one of them with javascript



Most of my code is just operations to a database..It doesn't do anything weird..I dont handle
threads or anything like that.



thanks.



From: Geoffrey Talvola <[EMAIL PROTECTED]>
To: 'sandra ruiz' <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
Subject: RE: [Webware-discuss] crash on double click
Date: Wed, 10 Dec 2003 10:15:51 -0500


sandra ruiz wrote:
> hi, list..i'm not quite sure if this problem its because of
> Weware..but when a user makes double click
> on a button in a form the server crash down..and returns a blank page.
>
> when i look for in the log of apache I get this error:
>
> [Fri Oct 24 16:15:31 2003] [error] [client 192.168.25.20] (20507)The
> timeout specified has expired: ap_content_length_filter:
> apr_bucket_read() failed,
> referer:..........
>
> I've looked for this error in Internet..but I've couldn't
> find an answer..
>
> The timeout of my apache is 5 minutes. that's enough for me.
> I am using
> webware 0.8
>
> thanks in advance.

Need more details.  Does this happen with _any_ servlet, or only with one
particular servlet?  If with one servlet, then what is that servlet doing
when you click the button?

Double-clicking the button will cause two identical requests to be POST'ed
at almost the same time.  If your code has thread-safety problems this is
one way to trigger them... but Webware itself is capable of handling this
fine.

- Geoff


------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for IBM's Free Linux Tutorials. Learn everything from the bash shell to sys admin. Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss

_________________________________________________________________
Consigue aqu� las mejores y mas recientes ofertas de trabajo en Am�rica Latina y USA: http://latam.msn.com/empleos/




-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to