Update / install cached array element in Memcache

CMS I use memcached by default and I am working on its extension. One key contains an array of user information, for example userstats_id, and contains information such as the number of posts in the forum, the number of posts that they like blah blah. The key is as follows:

[userstats_1] => Array
        (
            [forum_posts] => 178
            [forum_likes] => 16
            [forum_dislikes] => 0
            [now_online] => 1
        )

I am expanding the use of this key because I also want to keep which specific forums the user is viewing, for example:

[userstats_forumbrowsing_1] => Array
    (
        [forum_browsing] => 'Foobar'
    )

, [userstats_1], , , . , , , , ?

, , , , , . !

+5
1

, , memcached - , , .

, :

  • "" , : , get , , set .
  • get set .

, , .

- memcached Redis, , , , .

+5

All Articles