是否有内存中的键/值存储可以通知外部实体更改?

发布于 2024-10-03 07:43:50 字数 400 浏览 1 评论 0原文

我读过有关内存中键/值存储的内容,但从未实际使用过。我这个没受过教育的人首先想到的是 CouchDB 和 memcached(我知道 CouchDB 不一定在内存中,但经常这样使用)。

我正在寻找支持基本脚本编写的内存存储之一,以便我可以向外部实体(通过 RESTful API)通知更改。一些初步研究表明,CouchDB 支持名为 更改通知 的内容

Memcached 似乎不支持这种类型功能,并且是一种更通用的仅存储服务(再次,我的无知可能会在这里暴露出来)。

有人有这样做的经验吗?对于潜在的陷阱或令人头痛的问题,您有什么智慧的话吗?是否还有我未列出的其他软件支持这些功能?

I have read about in-memory key/value stores but have never actually utilized one. The first that come to my uneducated mind are CouchDB and memcached (I know CouchDB isn't necessarily in-memory, but is often used as such).

I am looking for one of these in-memory stores that support basic scripting, such that I could notify an external entity (through a RESTful API) of a change. Some preliminary research reveals that CouchDB supports something called Change Notifications

Memcached does not seem to support this type of feature, and is a more general storage-only service (again, my ignorance may shine through here).

Does anyone have any experience doing this? Any words of wisdom for potential pitfalls or headaches? Is there some other software I didn't list that would support these features?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

一绘本一梦想 2024-10-10 07:43:50

membase 实现memcached 点击协议以流式传输所有发生的突变。我们在此基础上构建了很多东西(复制是一个用例)。

membase implements the memcached tap protocol to stream out all mutations as they occur. We build a lot of stuff on top of that (replication is a use case).

愚人国度 2024-10-10 07:43:50

将 RAM 安装为磁盘并将其作为数据目录启动 couchdb 怎么样?

您可以将 ram 磁盘安装为:

$ mkdir -p /tmp/couchdb
$ sudo mount -t tmpfs tmpfs -o size=2G /tmp/couchdb

并更改 couchdb 配置文件以将数据存储在该目录中。

[couchdb]
database_dir = /tmp/couchdb
view_index_dir = /tmp/couchdb

启动 couchdb 并放松!

How about mounting RAM as disk and starting couchdb with that as data dir?

You can mount a ram disk as:

$ mkdir -p /tmp/couchdb
$ sudo mount -t tmpfs tmpfs -o size=2G /tmp/couchdb

And change the couchdb configuration file to store the data in that directory.

[couchdb]
database_dir = /tmp/couchdb
view_index_dir = /tmp/couchdb

Start couchdb and relax!

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文