-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpFoundation][Lock] Ensure compatibility with ext-mongodb v2 #58619
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
Merged
Conversation
This file contains hidden or 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 comment was marked as outdated.
This comment was marked as outdated.
GromNaN
commented
Oct 21, 2024
@@ -268,7 +268,7 @@ public function exists(Key $key): bool | |||
'$gt' => $this->createMongoDateTime(microtime(true)), | |||
], | |||
], [ | |||
'readPreference' => new ReadPreference(\defined(ReadPreference::PRIMARY) ? ReadPreference::PRIMARY : ReadPreference::RP_PRIMARY), |
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.
The existing code is incorrect: it checks the existence of the constant value. See the conversation why this condition was added: #37140 (comment)
This was removed in 6.4 by bc24cb3#diff-d0f7d4ac57862532ef468d4fa38f1879eeb1c6e6f142118ecfa28dba891601b4L266
alcaeus
approved these changes
Oct 22, 2024
chalasr
approved these changes
Oct 22, 2024
OskarStark
approved these changes
Oct 22, 2024
Thank you @GromNaN. |
nicolas-grekas
added a commit
that referenced
this pull request
Oct 25, 2024
This PR was merged into the 6.4 branch. Discussion ---------- [Lock] Ensure compatibility with ext-mongodb v2 | Q | A | ------------- | --- | Branch? | 6.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | - | License | MIT Same as #58619 for branch 6.4 that was reworked by #52336 Commits ------- cd3b778 Ensure compatibility with ext-mongodb v2
This was referenced Oct 27, 2024
Merged
Merged
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The extension
mongodb
and the librarymongodb/mongodb
will soon have a version 2.0 that brings breaking changes (see extension changes and library changes). This PR ensures compatibility with the upcoming version for Symfony 5.4.MongoDB\Collection::updateOne()
, the closure in the mockwillReturnCallback
must return an object. PHPLIB-954: Add return types to all methods mongodb/mongo-php-library#1391MongoDB\Driver\Exception\WriteException
removed in favor ofBulkWriteException
PHPC-2348 RemoveWriteException
and movegetWriteResult
toBulkWriteException
mongodb/mongo-php-driver#1685. No need to keep catchingWriteException
since a the driver bulk API have always be used.float
support to constructMongoDB\BSON\UTCDateTime
is removed PHPC-2459: Remove support for float arg in UTCDateTime ctor mongodb/mongo-php-driver#1709