richardbergquist
Programmer
Hi all,
We have a java web app (running on Tomcat) that performs an user registration process. A pretty standard internet experience right? We have havning trouble with users double clicking on the 'I accept' button and getting errors because the second transaction fails as the user details has already been recorded in the back end.
Now this must be a really common problem. It seems many sites get around it with java script - which is not a real option as it means different browsers may or may not perform the javascript. We have to implement a solution in the backend (i.e Tomcat servlets) Anybody done this before ?
We have set up some classes that perform a form of transaction locking by interting data into the HttpSession which kinda works. It allows the transaction to be performed only once. Trouble is on the second click we need to navigate somewhere but we don't know the success of the first click.
Before I launch off into a whole bunch of session objects wrangling I thought I'd ask if anybody has come across this and solved it in a nice clean way.
My other solution, is of course, just to shoot the users how can't use a browser correctly.
RjB
RjB.
We have a java web app (running on Tomcat) that performs an user registration process. A pretty standard internet experience right? We have havning trouble with users double clicking on the 'I accept' button and getting errors because the second transaction fails as the user details has already been recorded in the back end.
Now this must be a really common problem. It seems many sites get around it with java script - which is not a real option as it means different browsers may or may not perform the javascript. We have to implement a solution in the backend (i.e Tomcat servlets) Anybody done this before ?
We have set up some classes that perform a form of transaction locking by interting data into the HttpSession which kinda works. It allows the transaction to be performed only once. Trouble is on the second click we need to navigate somewhere but we don't know the success of the first click.
Before I launch off into a whole bunch of session objects wrangling I thought I'd ask if anybody has come across this and solved it in a nice clean way.
My other solution, is of course, just to shoot the users how can't use a browser correctly.
RjB
RjB.