
On Wed, Dec 31, 2008 at 20:53, Robert Ramey
Thank u vĂ…ry much.
In regard to const char * type, i use it just a stupid c-strings, caz i need maximum performance. p.s. In my app keys are immutable.
Then why are you storing them in a file? That's the red flag.
My app is something like memcached daemon, but with addiotional commands flush/load for dumping current state to persistent storage(disk).
Since you're concerned about performance, why are you storing immutable data?
I store current state of storage (just serialize all elements of map) for backup. If daemon segfaults of even server reboot, daemon lose only data since last flush commad was. So, typical usage of daemon: E.g. Another app(adv. rotation system) have some counters(impressions today, impressions total, clicks today, etc). Many process set/get/inc/dec many counters. Each process communicate with daemon using simple textual protocol(i know that binary faster, but textual more useful for my purposes). map[immutable key] = value; Key never change, but value can.