-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Deprecated platform "commented type" API #5194
Comments
The solution would be contribute an implementation of |
Any customization of a specific type is not an option, I have given an example, we customize more types based on a platform. The customization makes sense to me, as not every DBAL type has to be natively supported as a Type impl. may expect implicitly. |
I read that 5 times and I don't understand… can you maybe rephrase? |
yes - previously it was possible from a platform to change the type definition like in: https://github.com/atk4/data/blob/develop/src/Persistence/Sql/Oracle/PlatformTrait.php#L22 and also the flag if the type is native or not (eg. if comment is added or not) my question is, as the in simple words, how to control if type should be commented from Platform side, not from the Type side |
You no longer can, sorry. If Oracle needs the |
the support is deprecated in https://github.com/doctrine/dbal/pull/5058/files#diff-80f8e09bba3385ad6ffd160d565b52166f469a09b0c45b3cb0f93751490a3542L493 , why is the "commented type" API/method removed from Platform? Platform was always a great middleware to further customize a Type and when an user implements own Platform, he should be not required to reimplement all Types, which is not even (easily) possible in some projects that further extends the standard Types I am closing this issues as it seems |
Good point, I don't think we considered that. Anyway, we are probably going to remove comments entirely (see #5107), because they no longer seem useful since platform-aware schema comparison was implemented. |
No, please do not! When for ex. Different Type, even if stored in the same column type, can store the data differently, thus the DC2Type comment holds very important info. We rely on DC2Type heavily: and even use this info in DB triggers to enforce more integrity of the stored data. |
Consider adding a comment to #5107 explaining why you feel it is important to be able to resolve types back from the database. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
https://github.com/doctrine/dbal/blob/3.3.x/UPGRADE.md#deprecated-platform-commented-type-api
Support Question
AbstractPlatform::initializeCommentedDoctrineTypes()
seems removedwhen a platform does not support some storage type natively (like from the coverage report above, we store binary as hex encoded string), we used this method to enforce DBAL to add a comment based on the platform
how this can be achived now?
The text was updated successfully, but these errors were encountered: