嵌入式沙发数据库
CouchDB 很棒,我喜欢它的p2p 复制功能,但它有点大(因为我们必须安装 Erlang)并且在桌面应用程序中使用时速度较慢。
正如我在intel duo core cpu中测试的那样,
- 加载10000个文档需要12秒,
- 插入10000个文档需要10秒,但更新视图需要20秒,所以总共需要30秒
是否有任何具有相同p2p复制的No SQL实现 功能,但大小像sqlite一样很小,而且速度相当不错(1秒加载10000个文档)。
CouchDB is great, I like its p2p replication functionality, but it's a bit larger(because we have to install Erlang) and slower when used in desktop application.
As I tested in intel duo core cpu,
- 12 seconds to load 10000 docs
- 10 seconds to insert 10000 doc, but need 20 seconds to update view, so total is 30 seconds
Is there any No SQL implementation which has the same p2p replication functionality, but the size is very small like sqlite, and the speed is quite good(1 second to load 10000 docs).
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否尝试过使用 Hovercraft 和/或 Erlang 视图服务器?我遇到了类似的问题,并发现留在 Erlang VM 中(从而避免了访问 SpiderMonkey)给了我所需的提升。我做了 3 件事...
增强查询:将 MapReduce 函数从 js 移植到“原生”Erlang 通常会在查询 couch 时带来巨大的性能提升(http://wiki.apache.org/couchdb/EnableErlangViews)。此外,管理视图更容易,因为您可以调用外部库或您自己编译的模块(只需将它们添加到您的 ebin 目录),减少您在开发过程中需要执行的上传数量。
增强插入:使用 Hovercraft 进行插入可将性能提高 100 倍 (https://github.com/jchris/hovercraft。) CouchDB 书中提到了这一点 (http://guide.couchdb.org/draft/ 增强插入:使用 Hovercraft进行
预运行视图:对于桌面应用程序,您可以做的最后一件事是在应用程序启动期间运行视图(例如,当显示启动屏幕时)。第一次视图是run 总是最慢的,后续运行会更快。
这些对我帮助很大。
Have you tried using the Hovercraft and/or the Erlang view server? I had a similar problem and found staying within the Erlang VM (thereby and avoiding excursions to SpiderMonkey) gave me the boost I needed. I did 3 things...
Boosting Queries: Porting your mapreduce functions from js to "native" Erlang usually gives tremendous performance boost when querying couch (http://wiki.apache.org/couchdb/EnableErlangViews). Also, managing views is easier coz you can call external libs or your own compiled modules (just add them to your ebin dir) reducing the number of uploads you need to do during development.
Boosting Inserts: Using Hovercraft for inserts gives upto X100 increase in performance (https://github.com/jchris/hovercraft.) This was mentioned in the CouchDB book (http://guide.couchdb.org/draft/performance.html)
Pre-Run Views: The last thing you can do for desktop apps is run your views during application startup (say, when the splash-screen is showing.) The first time views are run is always the slowest, subsequent runs are faster.
These helped me a lot.
不幸的是,这个问题没有提供有关您的应用程序要求的足够详细信息,因此很难提供建议。无论如何,我不知道有任何其他存储解决方案提供类似/高级的 P2P 复制。
关于您的要求的几个问题/评论:
您可能想看看:
还可以查看 http://nosql.mypopescu 上列出的一些其他 NoSQL 解决方案.com 不符合您的应用要求。
Unfortunately the question doesn't offer enough details about your app requirements so it's kind of difficult to offer an advise. Anyways, I'm not aware of any other storage solution offering a similar/advanced P2P replication.
A couple of questions/comments about your your requirements:
You might want to take a look at:
Also check some of the other NoSQL-solutions listed on http://nosql.mypopescu.com against your app requirements.