On Fri, 22 Jun 2007, Raymond Wan wrote:
> Hi Gareth,
>
> Gareth Kirwan wrote:
>>> I see, thanks! I was thinking of global variables or even <%init>
>>> blocks to set and store variables, but each request (even within a
>>> single persistent connection by the same client) is
>>> independent and no
>>> variable can exist across requests?
>>>
>>
>> Remember that your solutions need to be scalable.
>> That means that if you get busy you might end up using multiple backend
>> processes, if you're not already (most likely).
>> You may even end up with fastcgis on separate servers, with multiple web
>> servers in front of them.
>>
>> All of this means that you're unlikely to get the same perl process serving
>> this user the second time they make a request.
>>
>
>
> Yes, and I guess that is why the global variable I was using sometimes
> worked and sometimes didn't. By chance, I sometimes got the same Perl
> process. This has been an observation by at least one other person in
> recent weeks...
>
> One of those things that make newbies like me go "huh?". :-)
>
>
>> The direction I'm currently in favour of is using memcached for short term
>> variable storage, rather than a database.
>>
>
> I see. I'll look into that option but a whole database does seem
> overkill. Thank you!
CGI::Session (and I think Apache::Session os the mod_perl equivalent)
may be useful here.
:)
---------------------------------------------------------------------
| Name: Tim Nelson | Because the Creator is, |
| E-mail: [EMAIL PROTECTED] | I am |
---------------------------------------------------------------------
----BEGIN GEEK CODE BLOCK----
Version 3.12
GCS d+++ s+: a- C++$ U+++$ P+++$ L+++ E- W+ N+ w--- V-
PE(+) Y+>++ PGP->+++ R(+) !tv b++ DI++++ D G+ e++>++++ h! y-
-----END GEEK CODE BLOCK-----
-------------------------------------------------------------------------
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
[email protected]
https://lists.sourceforge.net/lists/listinfo/mason-users