-
Notifications
You must be signed in to change notification settings - Fork 264
PHPLIB-1627: BulkWriteCommand API #1630
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
d9351cc
to
33952f7
Compare
f2cae41
to
c4c0deb
Compare
The transaction spec requires certain language, and this is now expected in spec test for clientBulkWrite.
Also fixes the return type for getBuilderEncoder()
The spec tests need to be updated with mongodb/specifications@63e382e |
The previous failure was unrelated, but I'll update the spec tests once mongodb/mongo-php-driver#1822 is merged up to v2.x. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements the new BulkWriteCommand API and refactors several test and client modules to align with the updated driver options and error messaging. Key changes include:
- Removing redundant test helper methods and refactoring driver option handling.
- Introducing new stub files and operation classes for BulkWriteCommand support.
- Updating tests to reflect newly designed error messages and encoder/codec accessors.
Reviewed Changes
Copilot reviewed 41 out of 41 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
tests/SpecTests/ClientSideEncryption/FunctionalTestCase.php | Removed redundant createTestClient method to use inherited behavior. |
tests/PedantryTest.php | Updated method filtering to re-index arrays and exclude non-public constructors. |
tests/FunctionalTestCase.php | Refactored driver option handling with renamed method appendDriverOptions. |
tests/Collection/CollectionFunctionalTest.php | Added tests for getBuilderEncoder and getCodec, and updated expected exception messages. |
stubs/Driver/*.stub.php | Added stub files for new BulkWriteCommand API components. |
src/Operation/ClientBulkWriteCommand.php | Introduced new operation for executing bulk write commands with updated options handling. |
src/ClientBulkWrite.php | Implemented a fluent API for bulk write operations with proper option validations. |
src/Client.php | Added bulkWrite method integrating the new BulkWriteCommand API. |
Configuration files and workflows | Updated dependency versions and driver version settings with TODO notes. |
Co-authored-by: Copilot <[email protected]>
@@ -12,7 +12,9 @@ on: | |||
- "feature/*" | |||
|
|||
env: | |||
DRIVER_VERSION: "stable" | |||
# TODO: change to "stable" once 2.0.0 is released |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# TODO: change to "stable" once 2.0.0 is released | |
# TODO: change to "stable" once 2.1.0 is released |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Great work @jmikola
https://jira.mongodb.org/browse/PHPLIB-1627
Requires mongodb/mongo-php-driver#1818