[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-4941":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":10,"pushedAt":10,"updatedAt":26,"readmeContent":27,"aiSummary":28,"trendingCount":16,"starSnapshotCount":16,"syncStatus":17,"lastSyncTime":29,"discoverSource":30},4941,"groupcache","golang\u002Fgroupcache","golang","groupcache is a caching and cache-filling library, intended as a replacement for memcached in many cases.","",null,"Go",13333,1393,460,25,0,2,7,1,44.43,"Apache License 2.0",false,"master",true,[],"2026-06-12 02:01:06","# groupcache\n\n## Summary\n\ngroupcache is a distributed caching and cache-filling library, intended as a\nreplacement for a pool of memcached nodes in many cases.\n\nFor API docs and examples, see http:\u002F\u002Fgodoc.org\u002Fgithub.com\u002Fgolang\u002Fgroupcache\n\n## Comparison to memcached\n\n### **Like memcached**, groupcache:\n\n * shards by key to select which peer is responsible for that key\n\n### **Unlike memcached**, groupcache:\n\n * does not require running a separate set of servers, thus massively\n   reducing deployment\u002Fconfiguration pain.  groupcache is a client\n   library as well as a server.  It connects to its own peers, forming\n   a distributed cache.\n\n * comes with a cache filling mechanism.  Whereas memcached just says\n   \"Sorry, cache miss\", often resulting in a thundering herd of\n   database (or whatever) loads from an unbounded number of clients\n   (which has resulted in several fun outages), groupcache coordinates\n   cache fills such that only one load in one process of an entire\n   replicated set of processes populates the cache, then multiplexes\n   the loaded value to all callers.\n\n * does not support versioned values.  If key \"foo\" is value \"bar\",\n   key \"foo\" must always be \"bar\".  There are neither cache expiration\n   times, nor explicit cache evictions.  Thus there is also no CAS,\n   nor Increment\u002FDecrement.  This also means that groupcache....\n\n * ... supports automatic mirroring of super-hot items to multiple\n   processes.  This prevents memcached hot spotting where a machine's\n   CPU and\u002For NIC are overloaded by very popular keys\u002Fvalues.\n\n * is currently only available for Go.  It's very unlikely that I\n   (bradfitz@) will port the code to any other language.\n\n## Loading process\n\nIn a nutshell, a groupcache lookup of **Get(\"foo\")** looks like:\n\n(On machine #5 of a set of N machines running the same code)\n\n 1. Is the value of \"foo\" in local memory because it's super hot?  If so, use it.\n\n 2. Is the value of \"foo\" in local memory because peer #5 (the current\n    peer) is the owner of it?  If so, use it.\n\n 3. Amongst all the peers in my set of N, am I the owner of the key\n    \"foo\"?  (e.g. does it consistent hash to 5?)  If so, load it.  If\n    other callers come in, via the same process or via RPC requests\n    from peers, they block waiting for the load to finish and get the\n    same answer.  If not, RPC to the peer that's the owner and get\n    the answer.  If the RPC fails, just load it locally (still with\n    local dup suppression).\n\n## Users\n\ngroupcache is in production use by dl.google.com (its original user),\nparts of Blogger, parts of Google Code, parts of Google Fiber, parts\nof Google production monitoring systems, etc.\n\n## Presentations\n\nSee http:\u002F\u002Ftalks.golang.org\u002F2013\u002Foscon-dl.slide\n\n## Help\n\nUse the golang-nuts mailing list for any discussion or questions.\n","groupcache是一个分布式缓存和缓存填充库，旨在替代许多场景下的memcached。其核心功能包括基于键的分片选择负责该键的节点、无需单独运行服务器集群从而简化部署配置、具备缓存填充机制避免数据库负载风暴、支持超级热门项自动镜像到多个进程中以防止热点问题。groupcache适合用于需要高效缓存解决方案但又不想管理额外缓存服务器的应用场景，特别是在Go语言环境中寻求比传统memcached更灵活且易于集成的缓存方案时。","2026-06-11 03:01:40","top_language"]