Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Session_OnEnd no longer fires

Session_OnEnd no longer fires

Scheduled Pinned Locked Moved Web Development
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    achimera
    wrote on last edited by
    #1

    This is just a note to anyone else who might experience the same problem. In a classic ASP environment, after installing SP2 to Windows Server 2003, the Session_OnEnd event in Global.asa no longer fires. I created the following demo web site (containing ONLY these two files) to demonstrate... Default.asp:

    <html>
    <body>
    <%= Application("Trace") %>
    </body>
    </html>

    Global.asa:

    <SCRIPT LANGUAGE=JScript RUNAT=Server>
     
    function Application_OnStart()
    {
    Application("Trace") = "WAITING FOR ANY SESSION TO END...";
    }
     
    function Session_OnStart()
    {
    Session("Dummy") = "Dummy"; // just so something is in the session
    }
     
    function Session_OnEnd()
    {
    Application("Trace") = "SESSION END FIRED";
    }
     
    </SCRIPT>

    The web site will ALWAYS display "WAITING FOR ANY SESSION TO END...". No matter how long you wait and check back. I see no solution. :sigh: If anyone has one, please let me know. Thanks.

    G V 2 Replies Last reply
    0
    • A achimera

      This is just a note to anyone else who might experience the same problem. In a classic ASP environment, after installing SP2 to Windows Server 2003, the Session_OnEnd event in Global.asa no longer fires. I created the following demo web site (containing ONLY these two files) to demonstrate... Default.asp:

      <html>
      <body>
      <%= Application("Trace") %>
      </body>
      </html>

      Global.asa:

      <SCRIPT LANGUAGE=JScript RUNAT=Server>
       
      function Application_OnStart()
      {
      Application("Trace") = "WAITING FOR ANY SESSION TO END...";
      }
       
      function Session_OnStart()
      {
      Session("Dummy") = "Dummy"; // just so something is in the session
      }
       
      function Session_OnEnd()
      {
      Application("Trace") = "SESSION END FIRED";
      }
       
      </SCRIPT>

      The web site will ALWAYS display "WAITING FOR ANY SESSION TO END...". No matter how long you wait and check back. I see no solution. :sigh: If anyone has one, please let me know. Thanks.

      G Offline
      G Offline
      Guffa
      wrote on last edited by
      #2

      Hm? Why not keep the discussion in the same thread?

      --- single minded; short sighted; long gone;

      A 1 Reply Last reply
      0
      • G Guffa

        Hm? Why not keep the discussion in the same thread?

        --- single minded; short sighted; long gone;

        A Offline
        A Offline
        achimera
        wrote on last edited by
        #3

        The original thread was a plea for help (one in which I did not know the answer). This thread was posted separately, as a sort of "post mortem" -- to simply point out a bug in SP2 -- which will hopefully allow someone else experiencing the same problem to more easily become aware of the issue. If I could delete the other thread entirely, I would -- as it is rather pointless now.

        G 1 Reply Last reply
        0
        • A achimera

          The original thread was a plea for help (one in which I did not know the answer). This thread was posted separately, as a sort of "post mortem" -- to simply point out a bug in SP2 -- which will hopefully allow someone else experiencing the same problem to more easily become aware of the issue. If I could delete the other thread entirely, I would -- as it is rather pointless now.

          G Offline
          G Offline
          Guffa
          wrote on last edited by
          #4

          I see no such difference between this thread and the previous. You have a bug, but you have not managed to identify it, so there is no telling if the bug is in your code or in the system. The fact that your code has not changed does not free it from suspicion.

          --- single minded; short sighted; long gone;

          A 1 Reply Last reply
          0
          • G Guffa

            I see no such difference between this thread and the previous. You have a bug, but you have not managed to identify it, so there is no telling if the bug is in your code or in the system. The fact that your code has not changed does not free it from suspicion.

            --- single minded; short sighted; long gone;

            A Offline
            A Offline
            achimera
            wrote on last edited by
            #5

            Well, it's done now, isn't it. What do you want me to do? I can go delete all of my previous posts in the other thread if you want -- but that will leave a rather ugly mess now won't it? In regards to my code, specifically the example at the head of this thread -- it's ridiculous to even suggest that there is a bug in that code. It is the simplest possible example to illustrate the issue that I'm talking about. And it is a bug in SP2 -- simply by the definition that similar code has been working perfectly fine for YEARS on Windows 2000 Server, then YEARS more on Windows Server 2003 -- then SP2 is installed and BAM! -- it no longer works. And the technique is something that was promoted by Microsoft in the past. The culprit is SP2. And there is absolutely NO DOUBT in my mind that it is a bug -- either accidental -- or by intentional depreciation. Now, if there is some sort of work around -- then that is another issue entirely -- however I'm not aware of one and no one else has been able to offer one either.

            1 Reply Last reply
            0
            • A achimera

              This is just a note to anyone else who might experience the same problem. In a classic ASP environment, after installing SP2 to Windows Server 2003, the Session_OnEnd event in Global.asa no longer fires. I created the following demo web site (containing ONLY these two files) to demonstrate... Default.asp:

              <html>
              <body>
              <%= Application("Trace") %>
              </body>
              </html>

              Global.asa:

              <SCRIPT LANGUAGE=JScript RUNAT=Server>
               
              function Application_OnStart()
              {
              Application("Trace") = "WAITING FOR ANY SESSION TO END...";
              }
               
              function Session_OnStart()
              {
              Session("Dummy") = "Dummy"; // just so something is in the session
              }
               
              function Session_OnEnd()
              {
              Application("Trace") = "SESSION END FIRED";
              }
               
              </SCRIPT>

              The web site will ALWAYS display "WAITING FOR ANY SESSION TO END...". No matter how long you wait and check back. I see no solution. :sigh: If anyone has one, please let me know. Thanks.

              V Offline
              V Offline
              Vasudevan Deepak Kumar
              wrote on last edited by
              #6

              http://www.eggheadcafe.com/articles/20030416.asp[^]

              Vasudevan Deepak Kumar Personal Homepage Tech Gossips

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups