test.ical.ly | getting the web by the balls



PHP 5.4 with traits, Doctrine 2.2 and then Symfony3?

It shouldn’t be long until the first alpha version of PHP 5.4 will be released and with it there will be a lot of new features such as array dereferencing and traits to name but a few.

What does that mean to the roadmaps of Doctrine and Symfony?I just read a post by Benjamin Eberlei on the doctrine-dev mailing list where announces some early experiments with traits for Doctrine 2.2.

As far as I understand the experiments will probably be what the behaviours have been for Doctrine 1.2 and not go for the core of Doctrine at the moment.

But anyway I had to think that if these experiments turn out to be promising and all those new features seem beneficial to Doctrine (and they should be beneficial, otherwise they would be pointless in the first place) then it makes sense to make use of them. Only this would mean that people would have to upgrade to PHP 5.4 as well of course. It would mark such a move as a new major version which would be Doctrine 3.0.

And what would Symfony do? Leverage the new “Doctrine 3” and consequently force users to upgrade to PHP 5.4 as well and would lead to “Symfony 3.0”? Or stick with the old Doctrine 2?

Well of course this while topic is complete speculation at this moment but I think there is an answer to it already. The lose coupling of Symfony2 allows the user to use whatever Doctrine (or even Propel) version he choses as long as there is a bundle for it. So as long as Symfony does not switch to PHP 5.4 itself any user can choose to switch to “Doctrine 3” and PHP 5.4 or stick with Doctrine 2 and PHP 5.3.

Just think back to symfony 1 where all this would be much more of a controversy.

I can see only two things where there might be clashes for different version branches of Symfony and Doctrine.

  1. If the Symfony2 documentation choses to document Doctrine specific stuff (for example in a quickstart chapter) then it would have to chose a Doctrine version for its users. This could be considered ok as long as this choice is for the older version and therefore does not force its users to any PHP upgrade.
  2. I dread the thought of DoctrineBundle being complemented by Doctrine3Bundle. Hopefully there will be bundles for more than one version but please don’t put the version number in the bundlename.. somehow to me this seems untidy.

Still I think it’s so cool that Symfonys decoupledness provides for a good and probably quite long release stability.

· · · ·



Theme Design by devolux.nh2.me