V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
hulk
V2EX  ›  编程

golang lru cache

  •  
  •   hulk · Feb 6, 2017 · 4868 views
    This topic created in 3375 days ago, the information mentioned may be changed or developed.

    前一段时间由于 golang 项目开发需要使用到 lru cache, 找了当前开源的几个版本都不太符合需求,所以自己基于 groupcache 的 lru 之上手撸了一个,放出来让大家拍拍砖。我们自己的对于 lru cache 的基本需求:

    1. 能控制最大数目,超过可以剔除
    2. 支持过期时间

    地址: https://github.com/git-hulk/go-lru

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2631 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 11:09 · PVG 19:09 · LAX 04:09 · JFK 07:09
    ♥ Do have faith in what you're doing.