• Post Reply Bookmark Topic Watch Topic
  • New Topic

FBNS: Do I need to worry about using tokens for transaction processing?

 
Ian Warker
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi again.

Another quick question. I come from a Struts-ey background and we commonly use JavaScript or transaction tokens to prevent users from submitting again before processing is complete. Typically this means that when they click buttons quickly ad repeatedly a warning dialog appears.

Welcome to the world of Swing...

Do I need to worry about this kind of thing in the GUI, or am I thinking too hard.
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Posts: 12059
232
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ian,

You probably do not want users booking the same seat twice , but how you handle it is up to you.

If you create a separate thread to do the booking, you will have a more responsive networked client, but you will have to do something to ensure that only one transaction is outstanding at any given time.

If you do not create a separate thread to do the booking then there is no way that the user will be able to book twice. But then there is the risk that the system may appear unresponsive if there are network problems.

Regards, Andrew
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!