Skip to content

Conversation

@bartpolot
Copy link

  • Running against Atlas creates permission errors with the local db
  • The error message is lost since the throw uses a string and the catch tries to access an Error objects
  • Imitators like DocumentDB fail some of the initial commands but deliver useful index and sizing results, allow to ignore those first errors.

…le (or [backup, clusterMonitor, readAnyDatabase]) it fails on Atlas clusters with:

MongoServerError: not authorized on local to execute command { aggregate: "replset.minvalid", pipeline: [ { $indexStats: {} }, { $group: { _id: "$key", stats: { $push: { accesses: "$accesses.ops", host: "$host", since: "$accesses.since" } } } }, { $project: { key: "$_id", stats: 1, _id: 0 } } ], cursor: {}, apiVersion: "1", lsid: { id: UUID(<UUID>) }, $clusterTime: { clusterTime: Timestamp(1724256067, 1), signature: { hash: BinData(0, <HEX>), keyId: <NUM> } }, $db: "local" }
…ol to run on MongoDB imitators.

For instance on DocumentDB this results in:
MongoServerError: Feature not supported: getCmdLineOpts
MongoServerError: Feature not supported: getParameter
MongoServerError: local db creation is not supported
MongoServerError: Field 'type' is currently not supported
MongoServerError: Profiler (slow query logger) is supported via log exports to Amazon CloudWatch. For more information: https://docs.aws.amazon.com/documentdb/latest/developerguide/profiling.html
@zhangyaoxing
Copy link
Collaborator

zhangyaoxing commented Sep 24, 2024

The latest change already skipped the local/admin/config database for getting indexes. Other commits look good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants