in reply to Re^2: (mem)caching of ip prefixes?
in thread (mem)caching of ip prefixes?

Well, from what I can see, Cache::Memcached only allows you to store/share simple key/values pairs, not complex objects or data structures. So I don't see any way to use Net::Patricia in conjuction with C::MC.

If NET::Patricia is fast enough for your purpose, then I see no benefit of further 'caching', and no efficient way to 'share' the N::P object between processes. The next obvious option is to set up the N::P object as server.

There are all sorts of server types that you could use, and you could write it in Perl as a forking, pre-forking, threaded or select-driven. But using perl to develop a server for high-speed, short transaction services using a single, large, shared data object, the select-model is the only game in town.

To that end, POE::Component::Server::TCP or even POE::Component::Server::SimpleHTTP would probably serve [sic] your purposes with minimal programming cost.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."