mysql - Store perl array in memory for other perl instances -
i using perl script upon receiving parameters, check 1 value on database , executes other actions accordingly. since traffic increasing there lot of mysql reads/writes being executed , might affecting performance.
since data stored in mysql not complicated, wondering if better store array in memory can read/modified other perl instances ran.
is possible?
you can use shared memory
ipc::sharedmem low level core module
to non reinvent wheel, take to:
ipc::shareable allows tie variable shared memory making easy share contents of variable other perl processes. scalars, arrays, , hashes can tied. variable being tied may contain arbitrarily complex data structures - including references arrays, hashes of hashes, etc.
Comments
Post a Comment