KOPFZEILE friendlyGIS

Deutsche Version
Deutsche Version

Contents

Contact: info@friendlyGIS.com

Copyright© friendlyGIS® GmbH 2000-2010

Last update: February 1st, 2011

-->Tayloring the HTML templates

-->Configuration of the Dispatcher

view session data

SW-Lookup® stores some data each time a user logs in and therefore begins a session. The data is username, time and the IP address of the workstation from where the access takes place. This allows to control how often the system is used, and by whom it is used.

You may view session data at the magik prompt and delete older session information from the database. SW-Lookup® provides some simple methods to be invoked from the Magik prompt; a window interface is not provided because the session management is something only at the administration level and will not be used often.

List session info

The method list_session_info() defined on the class sepia allows output of session data on an arbitrary channel. The arguments are:

  1. The channel (stream), e.g. !output! for standard output
  2. The date, from which the data should be output (optional)
  3. The date, up to which the data should be output (optional)

In order to provide, for example, a list of sessions from November 11th, 2003, input the following:

sepia.list_session_info(!output!, date.from_string("11.11.2003","#d.#m.#Y"))
$
11.11.03 21:38:20: hh@192.168.9.33 (192.168.9.33) - 18
11.11.03 21:40:12: hh@192.168.9.33 (192.168.9.33) - 19
11.11.03 21:48:20: hh@192.168.9.33 (192.168.9.33) - 20
12.11.03 19:30:47: hh@luise.hh.gt (192.168.9.21) - 21

The examples use german date formats, you should change this according to your country settings.

Delete older session data

If you are sure not to need old session data, you may delete these regularly to save space in sepia.ds.

This is the purpose of the method sepia.purge_sessions_before(), which deletes all session data before a given date. The following arguments are accepted:

  1. The channel (stream), e.g. !output! for standard output
  2. The date, before which the data should be deleted

In order to delete all session data from sessions BEFORE November 15th, 2003, you would enter:

sepia.purge_sessions_before( !output!, date.from_string("15.11.2003","#d.#m.#Y") )
$
DELETE: 14.11.03 10:25:29: hh@luise.hh.gt (192.168.9.21) - 22
DELETE: 14.11.03 10:25:33: hh@luise.hh.gt (192.168.9.21) - 23
DELETE: 14.11.03 11:06:46: hh@luise.hh.gt (192.168.9.21) - 24

TIP:The session data is needed during login to provide unique session ids. If you wish not to keep the session data, you should run a script each night which deletes all session data before the next day. This ensures that no session is kept longer than technically needed.

-->Tayloring the HTML templates

-->Configuration of the Dispatcher