SitePoint Sponsor

User Tag List

Page 2 of 2 FirstFirst 12
Results 26 to 30 of 30
  1. #26
    SitePoint Wizard siteguru's Avatar
    Join Date
    Oct 2002
    Location
    Scotland
    Posts
    3,629
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    And remember, set oObject=Nothing, not 0.
    Ian Anderson
    www.siteguru.co.uk

  2. #27
    SitePoint Member
    Join Date
    Aug 2010
    Posts
    17
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi siteguru,

    I finally got round to testing the Sessions closure by adding the following code to my Global.asa file:

    Sub Application_OnStart
    Application("TEST")=""
    End Sub

    Sub Session_OnEnd
    Application("TEST")="I Fired"
    End Sub
    And it turns out that when the session has timed out, this variable (Application("TEST")) does not get set.. This can't be good. Does that imply that any session created is not being successfully released?

    Cheers,
    Tom

  3. #28
    SitePoint Member
    Join Date
    Aug 2010
    Posts
    17
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay, its been a few months. Some tears have been shed. But after banging the head on the desk for many a day, I think I've finally come across the solution to the Session problem..

    Just to remind you, the issue was that Session_OnEnd was not being called giving me a false representation of the number of users online and adding to my list of weird behaviour and problems.

    The solution comes from the fact that IIS 7 has this ASP->Debugging->Run On End Functions Anonymously value (in IIS Mgr) which is set to True by default. This, apparently, results in the Session_OnEnd functions not working under certain conditions (my app pool runs anonymously I think).

    I have set this value to False, and since then my session counter stays at a sensible 1-100 range (we aren't that busy a site).

    In addition, I have had some cookie issues where carts were disappearing when people switched to secure http. This can be traced to the IIS Mgr->ASP->Session Properties->New ID On Secure Connection property, which also wants to be set to False if your carts use the session ID to store themselves...

    Finally, WRT the performance issues here. I have discovered some code that was present in the cart code (executed on every page) that was looping through a resultset of every product each time a new page was loaded! Needless to say I removed it and the spikes turned into very little bumps..

    The memory footprint of the W3WC.exe process still around the 50-100MB range and along with a mail server and sql server this does keep the machine busy. But it is appearing a lot more stable.

    Since replacing Access with SQL Server I have seen a lot less 500 pages (none recently!) and the server isn't going down when problems occur. I have limited SQL Server to 100MB private memory max and disabled remote connections.

    Thanks very much for all your help. I hope these notes help anyone else who is suffering from these kinds of problems in the future.

    Cheers,
    Tom

  4. #29
    SitePoint Wizard siteguru's Avatar
    Join Date
    Oct 2002
    Location
    Scotland
    Posts
    3,629
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Thanks for posting back with an update, Tom. Glad to hear you've broken the back of the issues.

    Hopefully you'll also get a resolution to your questions in your other thread.
    Ian Anderson
    www.siteguru.co.uk

  5. #30
    SitePoint Wizard bronze trophy
    Join Date
    Oct 2001
    Location
    Vancouver BC Canada
    Posts
    2,029
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the update Tom. I'm glad to hear you've tamed the "beast". It sounds like you've made some real improvements to the system too.

    I'll file away that tip about IIS7 ASP->Debugging->Run On End Functions Anonymously set to True... That is really good to know.

    Cheers,
    Andrew
    Andrew Wasson | www.lunadesign.org
    Principal / Internet Development


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •