Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Professional
|
ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 2nd, 2008, 12:18 PM
Authorized User
 
Join Date: Jun 2003
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Default Syncronizing Access to the Application Object

I have a problem in my web app if two browsers are open to my site and both are in the same IIS web session. To fix this I am giving each browser a seperate Hashtable to store what I was putting in the Session object. I'm storing at the Hashtable at the Application level. Here is my question.

Each browser request will look for its Hashtable in the Application, if not found it creates one, stores it in the Application, and then updates a "LastAccessed" value in the Hashtable so I can tell when it was last touched. A mechanism exists to remove Hashtables from Application if their "LastAccessed" is too old.

My question is, do I need to add special syncronization code around the Application object while inserting new Hashtables, modifying existing Hashtable values, and removing old Hashtables from the Cache?

Example. If one thead is inserting into the Application one Hashtable, while another thread is removing an old Hashtable, could this cause any kind of concurrency problem or is it thread safe enough as is?





Similar Threads
Thread Thread Starter Forum Replies Last Post
Alternative to application object ratheesh_param ASP.NET 1.x and 2.0 Application Design 3 November 15th, 2006 11:22 AM
application object ratheesh_param ASP.NET 1.0 and 1.1 Basics 1 November 8th, 2006 07:57 AM
Syncronizing webservice/client application version adyrotaru General .NET 0 September 16th, 2006 09:25 AM
Application object imagine Classic ASP Professional 11 November 1st, 2004 02:45 PM
syncronizing databases kev_79 Access 0 June 8th, 2004 01:59 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.