tomfs
V2EX  ›  问与答

LMDB:撸代码撸到蛋疼.

  •  
  •   tomfs · Aug 15, 2018 · 2380 views
    This topic created in 2861 days ago, the information mentioned may be changed or developed.

    LMDB 没群集方案,全靠手撸.

    后端 API 是 C++,nodes 是 go.两面都得撸.

    初定:

    1.nodes 用游标定位到数据量,然后根据数量量取请求后端 API.

    2.后端 API 用游标根据请求的 id 去枚举总库,然后生成一个临时的差异 lmdb 小数据库,然后打包传输给 nodes.

    3.nodes 收到打包数据库,用游标 copy 差异数据到 nodes 数据库.

    各位有更好的办法同步数据吗?

    -尼古拉斯.鲁斯特 卒.

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3912 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 48ms · UTC 05:08 · PVG 13:08 · LAX 22:08 · JFK 01:08
    ♥ Do have faith in what you're doing.