You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Anthony Hinsinger <an...@univ-metz.fr> on 2004/06/01 15:40:08 UTC

data sharing.

Hello,

I'd like to share a hash table between all apache processes (i'm using
apache 1.3.x and mod_perl 1.27)
Each process must be able to add and remove key/value in this hash
(values are perl blessed objects)

Does anyone has experiences with this kind of problem ?

Thanks

Anthony Hinsinger


-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html


Re: data sharing.

Posted by Jens Gassmann <je...@atomix.de>.
Hi Perrin, hi list,

sorry, my Template Module use it and so i think it could be so bad, but 
i learn gladly in addition,

- Jens


Perrin Harkins wrote:
> On Tue, 2004-06-01 at 09:46, Jens Gassmann wrote:
> 
>>maybe IPC-SharedCache helps you:
>>http://search.cpan.org/~samtregar/IPC-SharedCache-1.3/SharedCache.pm
> 
> 
> I guess maybe you missed the rating where the module's own author says
> not to use it.
> 
> This is based on IPC::ShareLite, like several other IPC modules, and
> IPC::ShareLite is impractical for any significant amount of data.  To
> store a hash of objects it would have to serialize the entire hash and
> stuff it into shared memory on every update, and then de-serialize the
> entire hash on the other side every time you want to read a key from it.
> 
> This has all been discussed at great length and you can find it in the
> mailing list archives.  The current winners on my benchmarks for local
> (i.e. not a cluster of machines) sharing are BerkeleyDB, IPC::MM, and
> Cache::FastMmap.
> 
> - Perrin
> 


-- 
Der Kopf ist rund, damit das Denken die Richtung ändern kann!

E-Mail:   jens.gassmann@atomix.de
Internet: http://www.atomix.de/
Mobil:    0179/1361016

-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html


Re: data sharing.

Posted by Perrin Harkins <pe...@elem.com>.
On Tue, 2004-06-01 at 09:46, Jens Gassmann wrote:
> maybe IPC-SharedCache helps you:
> http://search.cpan.org/~samtregar/IPC-SharedCache-1.3/SharedCache.pm

I guess maybe you missed the rating where the module's own author says
not to use it.

This is based on IPC::ShareLite, like several other IPC modules, and
IPC::ShareLite is impractical for any significant amount of data.  To
store a hash of objects it would have to serialize the entire hash and
stuff it into shared memory on every update, and then de-serialize the
entire hash on the other side every time you want to read a key from it.

This has all been discussed at great length and you can find it in the
mailing list archives.  The current winners on my benchmarks for local
(i.e. not a cluster of machines) sharing are BerkeleyDB, IPC::MM, and
Cache::FastMmap.

- Perrin


-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html


Re: data sharing.

Posted by Jens Gassmann <je...@atomix.de>.
Hello Anthony,

maybe IPC-SharedCache helps you:
http://search.cpan.org/~samtregar/IPC-SharedCache-1.3/SharedCache.pm

Regards,

jens
-- 

"If the facts don't fit the theory, change the facts" Albert Einstein

EMail: jens.gassmann@atomix.de
Handy: 0179/136 10 16
Büro : 0221/975 08 20





-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html