Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Maintaining state in modules

by KM (Priest)
on Sep 05, 2002 at 20:47 UTC ( #195497=note: print w/replies, xml ) Need Help??


in reply to Maintaining state in modules

Is it a CGI or non-CGI script? Look on the CPAN for 'session' to find ways to keep a session going, and store the info based on the session.

Why not make a base class and subclass it with a way to do it with dbm's. Then, subclass to use MySQL (or whatever). People can subclass to use with whatever data store they wish to use (a DB, flat file, directory structure, etc...) that way your design will make it more portable.

Also, look on the CPAN, and search Google for ways other are maintaining state, so you don't re-invent any wheels.

Cheers,
KM

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://195497]
help
Chatterbox?
[Discipulus]: if i can ask: which is the minimal (cheapest) configuration to have some hardware running a webserver with minimal traffic and wifi connection?
[marto]: Raspberry Pi 3?
[Discipulus]: thanks under 50 neuros it's a good thing!
[Discipulus]: and it's GPIO how are seen by the OS? Perl can speak thougth them?

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (8)
As of 2017-10-17 09:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My fridge is mostly full of:

















    Results (225 votes). Check out past polls.

    Notices?