-
Type: Task
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Component/s: Bulk API, Performance Benchmarking
-
Needed
-
Summary
Benchmark Collection::bulkWrite and Client::bulkWrite
Motivation
DRIVERS-716 adds Client::bulkWrite. A main motivation is improved performance noted in Product Description: Bulk Write API 2.0:
Improve write performance by reducing the number of round trips.
When Client::bulkWrite saves round-trips, it may significantly improve performance. However, BulkWrite Syntax Investigation notes:
Why is the current syntax slower than the alternate syntax?
Requests of the current syntax take longer to parse on the server compared to requests of the alternate syntax due to the format of the data.During testing we noticed that constructing the request on the client side was taking longer with the current syntax. We will have to defer to drivers to determine the performance implications of both syntaxes with regards to request construction.
Who is the affected end user?
Users wanting to use the new Client::bulkWrite.
How does this affect the end user?
Measuring may help inform future improvements to Client::bulkWrite, possibly resulting in improved performance.
How likely is it that this problem or use case will occur?
Not applicable?
If the problem does occur, what are the consequences and how severe are they?
Not applicable?
Is this issue urgent?
No.
Is this ticket required by a downstream team?
No.
Is this ticket only for tests?
Yes.
Acceptance Criteria
Benchmark Collection::bulkWrite and Client::bulkWrite with mixed operations (e.g. insert + update) in the same namespace. Expect a significant increase in throughput due to saved round trips.
Benchmark Collection::bulkWrite and Client::bulkWrite with insert-only operations in the same namespace. Expect an insignificant change in throughput due to similar number of round trips.
Additional Information
Consider adding benchmarks to MongoDB Driver Performance Benchmarking. The Small doc bulk insert and Large doc bulk insert benchmarks may be sufficient for benchmarking Collection::bulkWrite with insert-only operations.
Rust initially added Client::bulkWrite but does not implement Collection::bulkWrite. Suggest initially implementing the benchmarks in a driver that has both.
- is related to
-
DRIVERS-716 Improved Bulk Write API
- In Progress
-
PYTHON-4578 Add benchmarks for client.bulk_write and collection.bulk_write
- Closed
-
PYTHON-4596 Only encode each operation document once for MongoClient.bulk_write
- Closed
-
SERVER-93922 Reduce metadata overhead for bulkWrite command
- Open
- related to
-
DRIVERS-2954 Support the new Bulk Command use at the Database and Collection levels.
- Backlog
- split to
-
CDRIVER-5642 Benchmark Collection and Client bulkWrite
- Blocked
-
CSHARP-5203 Benchmark Collection and Client bulkWrite
- Blocked
-
CXX-3078 Benchmark Collection and Client bulkWrite
- Blocked
-
GODRIVER-3287 Benchmark Collection and Client bulkWrite
- Blocked
-
JAVA-5545 Benchmark Collection and Client bulkWrite
- Blocked
-
MOTOR-1346 Benchmark Collection and Client bulkWrite
- Blocked
-
NODE-6292 Benchmark Collection and Client bulkWrite
- Blocked
-
PHPLIB-1494 Benchmark Collection and Client bulkWrite
- Blocked
-
PYTHON-4833 Benchmark Collection and Client bulkWrite
- Blocked
-
RUBY-3522 Benchmark Collection and Client bulkWrite
- Blocked
-
RUST-2004 Benchmark Collection and Client bulkWrite
- Blocked