You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In MongoDocumentTreeView (lib/features/mongodb/mongo_document_tree_view.dart), appendJsonPath(parentPath, keyOrIndex) instantiates RegExp(r'^[a-zA-Z_$][a-zA-Z0-9_$]*$') inside the function on every single node of a document tree.
For 1,000 documents with 20 fields each, this results in 20,000 regex compilations and matcher allocations on every render.
Solution
Replace runtime RegExp construction with a zero-allocation character validation helper using codeUnitAt.
Cache or precompile static pattern if regex is retained.
Benefits
0 RegExp allocations during MongoDB tree traversal.
~15-20x faster path construction for nested documents.
Activity
Merge pull request #1610 from QueryaHub/issue/1525-mongo-json-path