-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[AD-604] Query execution adaption (#57)
### Summary [AD-604] Query execution adaption ### Description - Use JNI call to DocumentDbQueryMappingService to get the aggregate command pipeline. - Call server using mongocxx library - Map the result cursor so data_query returns the results - properly converted for query column metadata. - Ensure to handle null/missing elements in the query result. Ensure tests for: - [x] single row, SQLBindCol and SQLGetData - [x] multiple rows - [x] null/missing values - [x] array field - [x] sub-document field ### Related Issue https://bitquill.atlassian.net/browse/AD-604* [AD-604] Query execution adaption * [AD-604] Query execution adaption * Initial commit. 6 memory leaks detected. * [AD-604] Query execution adaption * Handle non-existent element in document. * [AD-604] Query execution adaption * Remove debugging code * Add tests (part 1) * Change import script to handle "jsonArray". * [AD-604] Query execution adaption * Add tests * [AD-604] Query execution adaption * Remove use of std::make_unique. * [AD-604] Query execution adaption * Fix import script. * [AD-604] Query execution adaption * Clean-up * [AD-604] Query execution adaption * Clean-up * [AD-604] Query execution adaption * Correct line endings. * [AD-604] Query execution adaption * Refactor class field names. * [AD-604] Query execution adaption * Fixed iterating over cursor - fixed memory leak. * [AD-604] Query execution adaption * Improvements from code review comments. * [AD-604] Query execution adaption * Improvements from code review comments. * [AD-604] Query execution adaption * Improvements from code review comments.
- Loading branch information
Bruce Irschick
authored
Apr 1, 2022
1 parent
1b8ae03
commit a206b45
Showing
39 changed files
with
2,463 additions
and
1,539 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
{ | ||
"_id":{ | ||
"$oid":"62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128":{ | ||
"$numberDecimal":"Infinity" | ||
}, | ||
"fieldDouble":1.7976931348623157E308, | ||
"fieldString":"新年快乐", | ||
"fieldObjectId":{ | ||
"$oid":"62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean":true, | ||
"fieldDate":{ | ||
"$date":"2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt":2147483647, | ||
"fieldLong":9223372036854775807, | ||
"fieldMaxKey":{ | ||
"$maxKey":1 | ||
}, | ||
"fieldMinKey":{ | ||
"$minKey":1 | ||
}, | ||
"fieldNull":null, | ||
"fieldBinary":{ | ||
"$binary":{ | ||
"base64":"AAEC", | ||
"subType":"00" | ||
} | ||
} | ||
} | ||
[ | ||
{ | ||
"_id": { | ||
"$oid": "62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128": { | ||
"$numberDecimal": "Infinity" | ||
}, | ||
"fieldDouble": 1.7976931348623157E308, | ||
"fieldString": "新年快乐", | ||
"fieldObjectId": { | ||
"$oid": "62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean": true, | ||
"fieldDate": { | ||
"$date": "2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt": 2147483647, | ||
"fieldLong": 9223372036854775807, | ||
"fieldMaxKey": { | ||
"$maxKey": 1 | ||
}, | ||
"fieldMinKey": { | ||
"$minKey": 1 | ||
}, | ||
"fieldNull": null, | ||
"fieldBinary": { | ||
"$binary": { | ||
"base64": "AAEC", | ||
"subType": "00" | ||
} | ||
} | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
{ | ||
"_id":{ | ||
"$oid":"62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128":{ | ||
"$numberDecimal":"Infinity" | ||
}, | ||
"fieldDouble":1.7976931348623157E308, | ||
"fieldString":"新年快乐", | ||
"fieldObjectId":{ | ||
"$oid":"62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean":true, | ||
"fieldDate":{ | ||
"$date":"2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt":2147483647, | ||
"fieldLong":9223372036854775807, | ||
"fieldMaxKey":{ | ||
"$maxKey":1 | ||
}, | ||
"fieldMinKey":{ | ||
"$minKey":1 | ||
}, | ||
"fieldNull":null, | ||
"fieldBinary":{ | ||
"$binary":{ | ||
"base64":"AAEC", | ||
"subType":"00" | ||
} | ||
} | ||
} | ||
[ | ||
{ | ||
"_id": { | ||
"$oid": "62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128": { | ||
"$numberDecimal": "Infinity" | ||
}, | ||
"fieldDouble": 1.7976931348623157E308, | ||
"fieldString": "新年快乐", | ||
"fieldObjectId": { | ||
"$oid": "62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean": true, | ||
"fieldDate": { | ||
"$date": "2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt": 2147483647, | ||
"fieldLong": 9223372036854775807, | ||
"fieldMaxKey": { | ||
"$maxKey": 1 | ||
}, | ||
"fieldMinKey": { | ||
"$minKey": 1 | ||
}, | ||
"fieldNull": null, | ||
"fieldBinary": { | ||
"$binary": { | ||
"base64": "AAEC", | ||
"subType": "00" | ||
} | ||
} | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
{ | ||
"_id":{ | ||
"$oid":"62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128":{ | ||
"$numberDecimal":"Infinity" | ||
}, | ||
"fieldDouble":1.7976931348623157E308, | ||
"fieldString":"新年快乐", | ||
"fieldObjectId":{ | ||
"$oid":"62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean":true, | ||
"fieldDate":{ | ||
"$date":"2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt":2147483647, | ||
"fieldLong":9223372036854775807, | ||
"fieldMaxKey":{ | ||
"$maxKey":1 | ||
}, | ||
"fieldMinKey":{ | ||
"$minKey":1 | ||
}, | ||
"fieldNull":null, | ||
"fieldBinary":{ | ||
"$binary":{ | ||
"base64":"AAEC", | ||
"subType":"00" | ||
} | ||
} | ||
} | ||
[ | ||
{ | ||
"_id": { | ||
"$oid": "62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128": { | ||
"$numberDecimal": "Infinity" | ||
}, | ||
"fieldDouble": 1.7976931348623157E308, | ||
"fieldString": "新年快乐", | ||
"fieldObjectId": { | ||
"$oid": "62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean": true, | ||
"fieldDate": { | ||
"$date": "2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt": 2147483647, | ||
"fieldLong": 9223372036854775807, | ||
"fieldMaxKey": { | ||
"$maxKey": 1 | ||
}, | ||
"fieldMinKey": { | ||
"$minKey": 1 | ||
}, | ||
"fieldNull": null, | ||
"fieldBinary": { | ||
"$binary": { | ||
"base64": "AAEC", | ||
"subType": "00" | ||
} | ||
} | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
{ | ||
"_id":{ | ||
"$oid":"8888f88886afa51ac62bed23" | ||
}, | ||
"fieldDecimal128":{ | ||
"$numberDecimal":"Infinity" | ||
}, | ||
"fieldDouble":3.1415926E23, | ||
"fieldString":"こんにちは", | ||
"fieldObjectId":{ | ||
"$oid":"888888caabcdef8888888888" | ||
}, | ||
"fieldBoolean":false, | ||
"fieldDate":{ | ||
"$date":"2022-03-08T00:00:00Z" | ||
}, | ||
"fieldInt":21345621, | ||
"fieldLong":9281883193847263322, | ||
"fieldMaxKey":{ | ||
"$maxKey":1 | ||
}, | ||
"fieldMinKey":{ | ||
"$minKey":1 | ||
}, | ||
"fieldNull":null, | ||
"fieldBinary":{ | ||
"$binary":{ | ||
"base64":"AAEC", | ||
"subType":"00" | ||
[ | ||
{ | ||
"_id": { | ||
"$oid": "8888f88886afa51ac62bed23" | ||
}, | ||
"fieldDecimal128": { | ||
"$numberDecimal": "Infinity" | ||
}, | ||
"fieldDouble": 3.1415926E23, | ||
"fieldString": "こんにちは", | ||
"fieldObjectId": { | ||
"$oid": "888888caabcdef8888888888" | ||
}, | ||
"fieldBoolean": false, | ||
"fieldDate": { | ||
"$date": "2022-03-08T00:00:00Z" | ||
}, | ||
"fieldInt": 21345621, | ||
"fieldLong": 9281883193847263322, | ||
"fieldMaxKey": { | ||
"$maxKey": 1 | ||
}, | ||
"fieldMinKey": { | ||
"$minKey": 1 | ||
}, | ||
"fieldNull": null, | ||
"fieldBinary": { | ||
"$binary": { | ||
"base64": "AAEC", | ||
"subType": "00" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,34 @@ | ||
{ | ||
"_id":{ | ||
"$oid":"62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128":{ | ||
"$numberDecimal":"Infinity" | ||
}, | ||
"fieldDouble":1.7976931348623157E308, | ||
"fieldString":"新年快乐", | ||
"fieldObjectId":{ | ||
"$oid":"62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean":true, | ||
"fieldDate":{ | ||
"$date":"2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt":2147483647, | ||
"fieldLong":9223372036854775807, | ||
"fieldMaxKey":{ | ||
"$maxKey":1 | ||
}, | ||
"fieldMinKey":{ | ||
"$minKey":1 | ||
}, | ||
"fieldNull":null, | ||
"fieldBinary":{ | ||
"$binary":{ | ||
"base64":"AAEC", | ||
"subType":"00" | ||
} | ||
} | ||
} | ||
[ | ||
{ | ||
"_id": { | ||
"$oid": "62196dcc4d91892191475139" | ||
}, | ||
"fieldDecimal128": { | ||
"$numberDecimal": "3.4028235e20" | ||
}, | ||
"fieldDouble": 1.7976931348623157E308, | ||
"fieldString": "some Text", | ||
"fieldObjectId": { | ||
"$oid": "62196dcc4d9189219147513a" | ||
}, | ||
"fieldBoolean": true, | ||
"fieldDate": { | ||
"$date": "2020-01-01T00:00:00Z" | ||
}, | ||
"fieldInt": 2147483647, | ||
"fieldLong": 9223372036854775807, | ||
"fieldMaxKey": { | ||
"$maxKey": 1 | ||
}, | ||
"fieldMinKey": { | ||
"$minKey": 1 | ||
}, | ||
"fieldNull": null, | ||
"fieldBinary": { | ||
"$binary": { | ||
"base64": "AAEC", | ||
"subType": "00" | ||
} | ||
} | ||
} | ||
] |
Oops, something went wrong.