mirror of
https://github.com/FerretDB/documentdb.git
synced 2026-11-25 11:49:53 -05:00
### Does this PR have any customer impact? No ### Type (Feature, Refactoring, Bugfix, DevOps, Testing, Perf, etc) Perf ### Does it involve schema level changes? (Table, Column, Index, UDF, etc level changes) No ### Are you introducing any new config? If yes, do you have tests with and without them being set? No ### Release Note (Refer [Template](../docs/release_notes/pgmongo_template.md)) No ### Description Migrate `$isNumber`, `$type`, `$toBool`, `$toObjectId`, `$toInt`, `$toLong`, `$toString`, `$toDate`, `$toDouble`, `$toDecimal`, and `$convert` to the new aggregation framework. ---- #### AI description (iteration 1) #### PR Classification Performance improvement for type aggregation operations. #### PR Summary This pull request optimizes the handling of type aggregation operations, specifically focusing on the `$convert` and `$makeArray` expressions. - `src/operators/bson_expression_type_operators.c`: Refactored the `$convert` expression to pre-parse and handle arguments more efficiently, reducing redundant evaluations and improving error handling. - Added new functions to handle pre-parsed `$convert` and `$makeArray` expressions, ensuring better performance and cleaner code structure. Related work items: #3458660