Hello, I am using MasonX-Request-WithApacheSession (specifically the Apache::Session:File class) and am attempting to store objects into the session, so that they can be used again latter in the application. However, the objects never store into the session properly. I have Mason configured via httpd.conf, using the ApacheHandler, as seen below:
PerlModule HTML::Mason::ApacheHandler PerlSetVar MasonDataDir /home/user/mason/www PerlSetVar MasonCompRoot /home/user/mason/www PerlSetVar MasonArgsMethod mod_perl PerlSetVar MasonRequestClass MasonX::Request::WithApacheSession PerlSetVar MasonSessionCookieDomain .domain.com PerlSetVar MasonSessionClass Apache::Session::File PerlSetVar MasonSessionDirectory /home/user/sessions/data PerlSetVar MasonSessionLockDirectory /home/user/dessions/locks PerlSetVar MasonSessionUseCookie 1 Here is what I have in my autohandler: > <%init> > use Net::LDAP; > if ( ! exists $m->session->{ldap} ) { > $m->session->{ldap} = new Net::LDAP( 'server.blah.tld' ); > } > $m->call_next; > <\%init> Then in a different component: > my $ldap = $m->session->{ldap}; > $m->print($ldap); But nothing is printed and if I look at the session file on the local system, the ldap entry is not added to it. However, if I change the autohandler to assign a string to $m->session->{ldap}, it is stored and passed properly. Is there something that I am missing? Should I not store objects in the session? Is there a better way to achieve this functionality? Thanks in advance, - James ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Mason-users mailing list Mason-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mason-users