Couchbase(例如 membase)解决方案将所有密钥转储到存储桶中
我在谷歌上搜索,发现了各种 python + tap 解决方案,这些解决方案应该使我能够从存储桶中转储所有密钥,但它们都不适合我。我在端口 11230 有一个存储桶,我需要转储所有密钥,以便将它们填充到 sphinx 搜索引擎中。
如果我执行:
# python /opt/couchbase/lib/python/tap_example.py 127.0.0.1:11230
我得到以下输出:
info: New bin connection from None
error: uncaptured python exception, closing channel <tap.TapConnection connected at 0x7f5d287184d0> (<type 'exceptions.AssertionError'>: [/usr/lib/python2.6/asyncore.py|read|78] [/usr/lib/python2.6/asyncore.py|handle_read_event|428] [/opt/couchbase/lib/python/mc_bin_server.py|handle_read|325])
即使我尝试其他主机或端口,此错误也是相同的。我还尝试了在论坛和群组中找到的许多其他 python 脚本,但它们都产生了相同的错误。
我的主要开发环境包括PHP和Perl 在 Debian linux 机器上,但我会采取任何解决方案,将所有密钥转储到纯文本文件中。
感谢您的帮助!
I was googling around and found various python + tap solutions that should enable me to dump all keys from a bucket but none of them worked for me. I have a bucket at port 11230 and I need to get a dump of all keys in order to fill them into sphinx search engine.
If I execute:
# python /opt/couchbase/lib/python/tap_example.py 127.0.0.1:11230
I get the following output:
info: New bin connection from None
error: uncaptured python exception, closing channel <tap.TapConnection connected at 0x7f5d287184d0> (<type 'exceptions.AssertionError'>: [/usr/lib/python2.6/asyncore.py|read|78] [/usr/lib/python2.6/asyncore.py|handle_read_event|428] [/opt/couchbase/lib/python/mc_bin_server.py|handle_read|325])
this error is the same even if I try some other host or port. I also tried many other python scripts that I found on forums and groups but all of them produced the same error.
My primary development environment includes PHP & Perl on Debian linux box but I will take any solution that would just dump all the keys into plain text file.
Thank you for any help!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
回复晚了,但您可以为此使用 couchbase 视图。
这将发出 json 存储桶中的每个键。
Late reply, but you could use a couchbase view for this.
This would emit every key in the bucket that is json.