Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Java Application ... on server?

 
Franco Lucci
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I have finally developed my first complete program (for the management of a cultural center).
The program works correctly but problem is a small (enormous)... must be used from more persons of the same company and therefore it would have to go on server and the other emplacements (client) would use it simultaneously.
TWO QUESTIONS:
1, What I have to use? a servlet, a RMI or an java application that the DB is shared?
2. How I can render the applications opened from the clients synchronized? (as an example when click on the customers the program makes a query SELECT * FROM CUSTOMERS but until that I don't make a refresh of the queryDataSet the query remains so even if an other client has cancelled a customer from an other emplacement and this also for the invoices and the course

Some suggestion.... thanks ^__^
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 35279
384
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Franco,
1) Any of those technologies would work. What do you have now, a Swing app? Unless your users want the program on the web, you could make remote calls to the database from the existing program.
2) There are two approaches for this. The first is to "lock" the tables when in use. This is somewhat unreliable because a user can go get coffee and never come back. The other approach is to keep track of a last updated timestamp. If the user has stale data, he cannot commit.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A Google search on "optimistic pessimistic locking" will turn up plenty of information about the two strategies.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Ben Souther:
A Google search on "optimistic pessimistic locking" will turn up plenty of information about the two strategies.


If not google, search the same forum atleast

Found a thread discussing the same thing. Confused about Locking
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic