Skip to content

fix(mongodb): search every field type and escape connection string options - #3786

Merged
datlechin merged 7 commits into
mainfrom
fix/mongodb-search-uri-escaping
Oct 22, 2026
Merged

datlechin merged 7 commits into
mainfrom
fix/mongodb-search-uri-escaping

Conversation

@datlechin

@datlechin datlechin commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Search All Rows on a MongoDB collection also matches numbers, dates, booleans and ObjectIds by the text the grid shows, from MongoDB 4.2. The plugin builds it once for both apps: contains, starts with and ends with add a guarded $regexMatch, since $convert throws past onError on binary data and on dates outside years 0 to 9999 (measured on 8.x). iOS drops its own version, which failed on such collections.
  • Connection string options are percent-encoded to RFC 3986 unreserved characters in the plugin and in the backup tools' URI. Typed parameters compare keys without case, and never override a field, including through old ssl* names or tlsInsecure while TLS is on.
  • Backup and restore: X.509 and AWS use $external, a bare IPv6 host gets brackets, TLS options no longer conflict.
  • A query tab on a NoSQL engine is never editable, so a tab name saved by an old build cannot send aggregation rows to a collection. Field kinds are learned only from whole-document finds, kept apart from write kinds, and a filtered page never retypes the fields it filtered on.
  • A filtered MongoDB count runs on the driver that read the page, so a nested date filter no longer counts 0.
  • A filter row that cannot be built matches nothing under Match All instead of running the rest.
  • Copy Connection String writes mongodb+srv:// and every option. URL query values decode once, so %2B stays +. An opened mongodb:// link keeps uuidRepresentation.
  • Probe: apple/scripts/probes/check-mongodb-shown-text.sh.
  • Tests changed on purpose: NativeDumpRegistryTests.mongoRequiredSkipsVerification (paths now encoded), the SSL cases in MongoDBPluginConnectionTests (uriOptions), the search cases in MongoDBOnIOSTests (built by the plugin).

Docs: TableProApp/docs#123 (draft).

Test plan

  • New: MongoDBQueryBuilderTests, MongoDBConnectionURITests (parsed back with libmongoc 1.28.1), cases in FindMatcherTests, ScopedDriverRoutingTests, PluginBrowsedQueryTabEditabilityTests, NativeDumpRegistryTests, ConnectionURLFormatterTests, ConnectionURLParserTests, PluginMetadataRegistryCuratedCapabilityTests.
  • Probe against MongoDB 8.3: 20 of 20 cases match, none raise.

@datlechin
datlechin enabled auto-merge (squash) October 22, 2026 12:29
@datlechin datlechin added the backport release/0.83 Merged into main; pick onto release/0.83 label Oct 22, 2026
@datlechin
datlechin merged commit 0fe45dd into main Oct 22, 2026
9 checks passed
@datlechin
datlechin deleted the fix/mongodb-search-uri-escaping branch October 22, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport release/0.83 Merged into main; pick onto release/0.83

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant