Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Problem passing CGI::Session between servers

by ColtsFoot (Chaplain)
on Jun 22, 2006 at 10:36 UTC ( [id://556875]=perlquestion: print w/replies, xml ) Need Help??

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

I have an application that creates a CGI::Session on Server1 and passes it around using http requests
Then at a certain point I need to make an https request to server2. I have no problem picking up the session on Server2.
Once the processing on Server2 is complete I perform a
my $url =qq(http://server1.xxx.yy.zz/cgi-bin/server1.pl?id=$id); $page->redirect($url);
server1.pl then executes the following code
my $session_dbh = DBI->connect('dbi:Pg:dbname=xyzzy') or die $DBI::err +str; my $id = $page->param('id'); my $session = CGI::Session->new("driver:PostgreSQL", $id, {Handle=>$se +ssion_dbh}); my $currid = $session->id();
When I then check the the two ids they do not match $currid is in fact a new session
and the old session has been deleted Any thoughts would be very helpful

UPDATE:Found it the clocks on server2 was an hour behind
and my session was set to expire after 15 mins so when
server1 went to check the last time the session had been active it
thought it had timed out :(

Replies are listed 'Best First'.
Re: OP's editing of parent
by ww (Archbishop) on Jun 22, 2006 at 17:46 UTC
    upvoted for the "UPDATE:Found it...."

    Similar conduct (ie: update, not replace; acknowledge glitches, post info on resolutions) by other SOPW would be greatly appreciated.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://556875]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chilling in the Monastery: (5)
As of 2024-04-25 15:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found