Jump to content

Close a session


jmonty77

Recommended Posts

Hello, what is the proper way of closing a session?

I've tried:

SessionManager.Sessions.PurgeSessionById(SessionId)

session.uniapplication.terminate('');

session.Terminate()

 

All this functions works in my developer server, but I've a production server where some sessions cannot be closed.

After calling this functions, I see that the mainmodule is not destroyed and if I list the sessions, I still can see that session:

     for I := 0 to self.SessionManager.Sessions.SessionList.Count - 1 do
        self.SessionManager.Sessions.SessionList;

       ....

I'm using an old version of unigui (1.0.0.1410). May be is it solved in current version?

 

Thank you

Jordi

 


 

 

 

Link to comment
Share on other sites

In a local network, when I detect a new session with same IP of another one that already exists, i want to close this older one.

I don't know from where came this older sessions, because my customer says that only one browser window is open at a time. And I see in logs that this sessions are not executing code anymore. They are listed, but cannot be freed.

My server is in a local network where clients modify their IP periodically, if it helps.

 

Link to comment
Share on other sites

I've this configuration. But talking about killing a session manually, it can be done?

What does "SessionManager.Sessions.PurgeSessionById(SessionId)"? I 've not found documentation, but this terminates a session when i try in my development server.

What situation can make that after calling this function, sessionid is still listed in session list forever?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...