GithubHelp home page GithubHelp logo

Comments (4)

starjun avatar starjun commented on August 19, 2024

1:后面有时间在改增量同步
2:还是那个ip封闭时间问题,还没想好怎么解决,永久的ip黑/白名单好整,那种动态产生的ip,以及封锁时间设置多少秒的,这个就麻烦了,暂没想好怎么解决这个问题。

from openstar.

h1z3y3 avatar h1z3y3 commented on August 19, 2024

redis 也可以设置expire time的, 具体: http://redisdoc.com/key/ttl.html

from openstar.

starjun avatar starjun commented on August 19, 2024

3Q,正在考虑增加这个功能。关于增量推送到redis有好的建议么?

from openstar.

h1z3y3 avatar h1z3y3 commented on August 19, 2024

我现在考虑的是,

  1. 关于配置项, 每次人为修改调用api可以先只更新redis, 然后在init_worker_by_lua*中调用
    ngx.timer.at(interval, updatefunc()) 几十秒全量更新下本地

2, 关于ip和统计, 数据量大 :

  1. 全量: 像你一样全量从内存=>redis
  2. 增量: 第一次加载nginx到内存后, 每次增删改, 分别修改对应字段 add/del/mod, 推送redis时只对这几个字段处理, 当然也是设置timer定时更新
  3. ip和统计数据比较大, 本地就不存了, 直接只存redis, 但是每次代价会很大好像. 所以基本不可取

from openstar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.