perl_lover has asked for the wisdom of the Perl Monks concerning the following question:

Is there any way to set session timeout for the session that are created with Apache::Session.

-Perl Lover-

Replies are listed 'Best First'.
Re: Apache::Session Session Timeout
by borisz (Canon) on Feb 07, 2005 at 15:39 UTC
    Put the last_access_time in the session and compare at the very beginning of the request if a timeout happened. If so revalidate the session and on success set a new last_access_time. If no timeout happened, set a new last_access_time.
    Boris
Re: Apache::Session Session Timeout
by Fletch (Bishop) on Feb 07, 2005 at 15:39 UTC

    Nothing jumps out in the API docs but one could always store a "createdat" timestamp in the object and check the age before using it.