Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session & Cookies conflict multiple windows

Status
Not open for further replies.

WIREMESH

Programmer
Mar 15, 2004
109
0
0
US
I have a desktop application that has been migrated to the web. In the desktop application, the users are accustomed to having multiple versions of the desktop application open simultanteously.

They what to have the same multi window access to the web app. Currently, the web app (ASP.NET 2.0) uses in process session variables (and a few cookies) to manage state. If the user opens the application in multiple web browsers (ex. 2 Windows Explorer browser sessions) from the same machine, will there be any conflict with either the session variables or cookies assuming the user accesses the same forms simultaneously?
 
it all depends on how you manage the cookies and session variables. technically no, there won't be a conflict. But you could always code yourself into a problem.

something to know up front. the web is not the desktop. no matter how hard you (and others) have tried. there is a difference. trying to convert one to the other doesn't make sense and leads to problems.

now there are ways to make the web UI modal so you can have multiple modal windows open, but again it's still the web and should be treated as such.

there are strengths and weaknesses to both the desktop and web environments. the best results come from embracing the enviornments strengths. not try to bend one environment to act like the other.

Jason Meckley
Programmer

faq855-7190
faq732-7259
 
The issue is not about modality. Basically, the systemis a help desk system for multiple clients. Each client has their own database (for contract related purposes). In the current desktop application, when users receive a call, they open the appropriate application. So, if I understand you answer, having the web application open in multipe browser sessions will not conflict with the session & cookies?
 
I don't understand why they have to have multiple windows open in the first place. Can't you just have them choose which DB to open from the app and then do what you need to do?
 
When they log into the system, that is when the database is chosen. Once they are logged into one of the databases, they keep that web browser session open. When they recieve another call from another client, they open another web browser session. So they will have at max 4 separate web browser sessions open, one for each database.
Back to my question.
 
You question has been answered by Jason.
Instead of them having multiple windows open, they should be taught to just connect to the database they need. The system should give them the ability to do that.
 
Why can't someone answer the question I asked.

This is a high volume environments, and the client wants the application to work this way for many reasons not enumarated here. I would like an aswer to my question, not application design advice.
 
Jason said:
it all depends on how you manage the cookies and session variables. technically no, there won't be a conflict
[/quote Jason]
 
were not trying to belittle your design or skillset, we are trying to help you avoid the pitfalls others, including us, have already fallen into.

with what you describe you will run probally run into problems. a session is user specific and a cookie is client specific. therefore a single user cannot log into multiple instances using the same account/machine. at least not without alot of messy code. and even then I'm not sure where to start to hack the asp.net framework to do so.

then there is the issue of client life time. the web is stateless. the way web servers works is after a period of inactivity a session ends (the user is logged off) typically 20 minutes. After a period of time without any activity by any user the website shuts down. this is by design to conserve server resources. you can override these defaults, but this is done through IIS not asp.net or webforms.

since the user needs to switch between databases i would have widget on the screen which allows the user to select which database they want to connect to. the user can only take one call at a time anyway.

Jason Meckley
Programmer

faq855-7190
faq732-7259
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top