You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wonder if the better way to deal with the Bundle, is rather than use all those mutators on Configuration that the Symfony Commands are ContainerAware and that they get the mongodb-migrations Configuration (or something like it) from the container. Then we set up a services.xml file with classes required.
That way they could be overridden (not sure how useful that would be) by the bundle user. Obviously it'll mean we can remove all the mutators and just get the configuration created once.
Scrutinizer gives
Configuration
class anF
:https://scrutinizer-ci.com/g/doesntmattr/mongodb-migrations/code-structure/master/class/AntiMattr%5CMongoDB%5CMigrations%5CConfiguration%5CConfiguration
It is not hard to see why.
There is this confusing inheritance model:
And there are a bunch of mutators on
Configuration
just so that the bundle can overwrite settings here: https://github.com/doesntmattr/mongodb-migrations-bundle/blob/master/Command/CommandHelper.php#L38Suggest we apply:
ConfigurationBuilder
Configuration
classConfigurationLoader
YamlLoader
XmlLoader
ContainerLoader
VersionCollection
These are just ideas. Would need to look more into how the
Configuration
class is used.Note that improvements here could also improve the Doctrine migrations library https://github.com/doctrine/migrations because it follows the same structure: https://scrutinizer-ci.com/g/doctrine/migrations/code-structure/master/class/Doctrine%5CDBAL%5CMigrations%5CConfiguration%5CConfiguration
The text was updated successfully, but these errors were encountered: