Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Major mixup in two ASP.NET transactions
Message
From
03/09/2006 04:59:15
 
 
To
02/09/2006 16:53:07
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
VB 8.0
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01150471
Message ID:
01150585
Views:
32
Hi,

>But, on all other hits, I am creating a private property of that global application object and use that instead. As this is private, this could work. What do you think?

Don't think that would work. You've always got just the one instance of your framework object that's potentially being hit from multiple threads. You could map your framework oRequest/oResponse properties to the current objects e.g:
  Public Property oResponse
        Get
           Return HttpContext.Current.Request
        End Get
   End Property
In the end, when you make a call to your framework object, you cannot assume that any per-request based information in it relates to the request actually making the call. In fact I think you have to address the general concurrency issues - all methods of the framework would need to be threadsafe (maybe Application.Lock()?) - and that's another performance hit (not sure about this - I've a feeling that HttpApplication itself is threadsafe to some degree but I've no documentation to hand).

I hate to say it but, although you could get this to work, I think it would be wise to rethink the design of the application...
Regards,
Viv
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform