command
Version:
v1.0.0-rc.3
Opens a new window with list of versions in this module.
Published: Oct 10, 2026
License: MIT
Opens a new window with license information.
Imports: 11
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
缓存化数据查询示例
运行 make up 后执行 make example-cached-query。示例使用 SQLite 保存权威商品数据,
使用 Genesis 本地缓存保存查询结果,并使用 Redis dlock 保护同一热点 key 的缓存重建。
首次读取会访问数据库并回填缓存;后续读取命中缓存,最终输出的数据库读取次数应为 1。
锁持有者在重建前后都检查缓存,避免等待锁的请求再次穿透到数据库。
Documentation
¶
There is no documentation for this package.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.