This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes Servlets and the fly likes Multiple access problem in webappication? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Multiple access problem in webappication?" Watch "Multiple access problem in webappication?" New topic
Author

Multiple access problem in webappication?

Ganeshkumar cheekati
Ranch Hand

Joined: Oct 13, 2008
Posts: 362
Hiii

If i login with different users into my application in two different tabs with in same browser then i am getting first login data in these two tabs so how can i rectify this problem? how can i avoid concurrency while implementing webapplications?


SCJP5 and SCWCD1.5
Think Twice Act Wise...
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

This is just how browsers are designed to work. Do you have many occasions where two users use the same browser at the same time?


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Ganeshkumar cheekati
Ranch Hand

Joined: Oct 13, 2008
Posts: 362
ofcourse.if two users are using my application in different browsers with same login credentails then Are they get mismatch in data? if so how can i avoid that?
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Really? Won't needing to take turns getting a shot on the keyboard make this sort of working prohibitively difficult?


if two users are using my application in different browsers with same login credentails then Are they get mismatch in data? if so how can i avoid that?

That's a different question. The answer is you can't, unless you prevent the second user logging in while the first user is using their credentials. Where you have two users accessing the same shared data you need to use techniques such as locking to prevent data loss. Seeing potentially out of date data in a web application is just a necessary fact of life, you need to write your application logic to be aware that this can and will happen.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Multiple access problem in webappication?
 
Similar Threads
session issues with multi tabs in a browser
Session inconsistencies
session issue with multi tabs in a browser
Multiple tabs share sessions so data in going into inconsistent state?
Session Timeout redirect to login page