Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有人可以确认CacheManager.Net是否支持redis管道?
我在文档中找不到
非常感谢。
干杯,你
有点儿。CacheManager 不直接支持任何批处理操作。
但在 Redis 的情况下,您可以使用cache.Put内部使用 StackExchange.Redis 的 fire and forget 标志。这是一种流水线,因为客户端在执行下一个操作之前不会等待一个操作完成。
cache.Put
如果您使用cache.Add(或更新等)代替,CacheManager 必须等待回复,例如,如果操作成功与否,也许该项目确实已经存在等等......
cache.Add
因此,如果您只想将大量数据推送到缓存中,请使用 Put。