Merged
Conversation
greg0ire
approved these changes
Feb 17, 2025
nicolas-grekas
added a commit
to symfony/symfony
that referenced
this pull request
Feb 18, 2025
….3 (alexandre-daubois) This PR was merged into the 6.4 branch. Discussion ---------- [DoctrineBridge] Fix deprecation with `doctrine/dbal` ^4.3 | Q | A | ------------- | --- | Branch? | 6.4 | Bug fix? | no | New feature? | no | Deprecations? | no | Issues | - | License | MIT Fixes deprecations raised by doctrine/dbal#6787. Commits ------- b1d5de5 [DoctrineBridge] Fix deprecation with `doctrine/dbal` ^4.3
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Before reworking
Indexsimilarly toUniqueConstraintandForeignKeyConstraint, I want to introducePrimaryKeyConstraint. Currently, they are represented as indexes with the "is primary" attribute set totrue, but there's no such thing as "primary index". On all supported platforms, a primary index is implemented as aPRIMARY KEYconstraint.Besides introducing such a class, I want to provide an upgrade path and implement a new API (e.g.
Table#getPrimaryKeyConstraint()) which would be state-compatible with the existing API. For instance, a user should be able to create a primary index and then access the primary key constraint.For that, I want to deprecate all invalid states that an index may currently have. The
IndexedColumnclass, particularly, will provide some guarantees for indexed column names and their lengths. Also, it will combine the name and the length together, which should be easier to use.Additionally, even though it currently works correctly, I'm deprecating using nullable columns in a primary index. The reasons are: