【问题标题】:Change Streams with Amazon DocumentDB使用 Amazon DocumentDB 更改流
【发布时间】:2020-11-19 12:06:57
【问题描述】:

我正在设置一个需要对 Amazon DocumentDB 的更改做出反应的微服务。在使用 MongoDB 时,我会使用 Reactive Change Streams。如果我使用 DocumentDB 执行此操作,则在注册更改侦听器时会出现异常,指出当前不支持更改流。

2019-02-12T11:46:15.513+0100 E QUERY    [js] Error: command failed: {
    "ok" : 0,
    "errmsg" : "The $changeStream stage is currently not supported",
    "code" : 303
} : aggregate failed :
_getErrorWithCode@src/mongo/shell/utils.js:25:13
doassert@src/mongo/shell/assert.js:18:14
_assertCommandWorked@src/mongo/shell/assert.js:534:17
assert.commandWorked@src/mongo/shell/assert.js:618:16
DB.prototype._runAggregate@src/mongo/shell/db.js:260:9
DBCollection.prototype.aggregate@src/mongo/shell/collection.js:1062:12
DBCollection.prototype.watch@src/mongo/shell/collection.js:1589:12
@(shell):1:1

对于“旧式”解决方案(op-log-tailing),我没有找到任何关于如何实现它的提示。

在 Amazon DocumentDB 上注册数据库更改的推荐设置是什么?

【问题讨论】:

  • 如果你使用 redis-oplog 可能有用吗?
  • 绝对值得一试。你有这方面的经验吗?

标签: amazon-web-services aws-documentdb-mongoapi


【解决方案1】:
【解决方案2】:

我会使用 dynamodb。为它而生

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-08-28
    • 1970-01-01
    • 2023-02-09
    • 1970-01-01
    • 2021-08-23
    • 2019-09-14
    • 1970-01-01
    相关资源
    最近更新 更多