I apologize for the perhaps obvious question, but I just started looking in the direction of these tools. I only know that one is old and the other is new. Can a respected community explain the difference between these tools and their scope?

Thank.

    1 answer 1

    There is no product called “memcache”, AFAIK.

    There is a “ memcached ” (fast key-value storage in memory), and there is a “ MemcacheDB ” (uses the memcached protocol, but stores data, if I remember correctly, in BerkeleyDB, providing persistence). Well, there are still any, using the protocol of the same memcached, Membase associates, with clustering, replication and other buns.

    Guess where the legs grow from. PHP has two clients, just called one “ memcache ” and the other “ memcached ”. Actually, there is a table with a comparison of these two clients, according to it, I think everything should be clear.

    pecl / memcachepecl / memcached
    First release2004-06-082009-01-29 (beta)
    External dependenciesNotlibmemcached
    Auto Key CorrectingÂąYesNot
    Add to start / endNotYes
    Automatic serializationYesYes
    Binary protocolNotOptional
    CASNotYes
    CompressionYesYes
    TimeoutsOnly connectVarious options
    Consistent hashingYesYes
    Deferred GETNotYes
    GET multiple values ​​per requestYesYes
    PHP session supportYesYes
    SET / GET to the specified serverNotYes
    Storing numbersConverted to stringsYes

    Âą) When trying to SET or GET to an incorrect key, memcache converts the incorrect key to the correct one, and returns false .

    • Yes, it is about the two clients in question. - Arni
    • OK. Then added a table with a comparison in response. If something is simple, memcache is perfect for most tasks, and if it’s more difficult (and there is libmemcached), memcached is more sophisticated. - drdaeman