memcached/membase 的代理 moxi

openkk 13年前發布 | 27K 次閱讀 memcached NoSQL數據庫 NOSQL

moxi 是一個 memcached/membase 的代理,支持多線程、支持文本和二進制協議和 libevent

可動態配置池的參數。moxi會在本地緩存,使得moxi相當于memcache server的前端cache,能減少network hops

  • Open-source, same BSD license as memcached.
  • Written in C.
  • Based on the latest memcached server code for its high-performance connection and protocol handling.
  • Uses the libmemcached for its rich hashing features (consistent hashing, etc).
  • Uses libevent for both upstream (client) and downstream connection handling.
  • Test suites
    • moxi aims to pass all the relevant memcached server compatibility tests.
    • moxi has many new test cases to exercise proxy-only features and topologies.
  • Protocol support
    • memcached text protocol, for upstream and downstream communication
    • memcached binary protocol, for downstream communication
    • later:
      • binary support for upstream communication
      • mixing and matching protocols (eg, some downstream servers are text, some are binary).
  • Optimizations
    • Multi-get Escalation and Protocol Pipelining - de-duplicates requests for popular keys, based on ideas from Dustin Sallings' spymemcached Java client library for memcached. See: http://code.google.com/p/spymemcached/wiki/Optimizations
    • Minimal locks - our aspiration is to have no new locks as part of the "main loop" of protocol handling.
    • Timeouts - set maximum time for operations. eg, "no downstream memcached operation should take more than X ms."
  • Lots of statistics tracked.
    • Statistics are tracked without extra locks, independently on each thread, optimized for the 99% case of being a good proxy. A once-in-awhile request for proxy statistics does an internal scatter-gather to aggregate statistics.
  • Live reconfiguration
    • Separate management channel (in the works) to allow dynamic server pool reconfigurations.
  • Simplified deployment
    • Assuming you run moxi on your web/app server boxes, your development, staging and production configurations gets easy: always point your memcached clients to "localhost:11211" (or whatever port you run moxi on).
  • Features inherited from memcached
    • moxi still has all the same code of memcached, and passes all the tests that memcached passes, so you can use moxi as a memcached server if you wish.
    • Multi-platform
    • Multi-threaded
    • Daemonizable
    • Run as another user
    • Bindable to IP interface, default is INADDR_ANY
    • PID file
    • etc

項目主頁:http://www.baiduhome.net/lib/view/home/1322722551030

 本文由用戶 openkk 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
 轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
 本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!