Symfony 2.2.0
March 1, 2013 • Published by Fabien Potencier
It's a wrap! Symfony 2.2.0 is now available and this is the first Symfony2 release that was driven by our new release process. First and foremost, I want to sincerely thank the Symfony community (developers, authors, bloggers, speakers, ...) who helped us on this release; everybody did a wonderful job in implementing new features, writing documentation for them, and fixing, tweaking, enhancing our existing code base.
Numbers
What can I say about this new release? As planned, Symfony 2.2.0 took 6 months and is made of 711 pull requests containing 2,035 commits and submitted by 44 developers for the code (47,191 additions and 13,512 deletions); documentation enjoyed 1,312 commits by 41 authors (13,038 additions and 3,336 deletions).
2,035 commits on a 6 month period means that, on average, 11 commits were pushed every single day. 711 pull requests means 4 pull requests merged per day.
Features
Numbers are not that interesting when it comes to upgrading, so what about the new features and the major changes? I won't list them all as most of them were discussed on this blog during the last few months:
- Console: Autocomplete on the command line;
- Console: Progress bars for long running tasks;
- Console: Hiding passwords given from the CLI;
- Console: Asking the user to choose from a list of choices;
- Finder: Filtering by path;
- Finder: Glob Support for the in() method;
- Finder: Speedup on some Platforms;
- HttpKernel: A new sub-framework to manage resource fragments;
- HttpKernel: Nice fatal errors display;
- HttpKernel: The logging of deprecated calls;
- Process: Getting incremental Output from a Process;
- Process: Restarting a Process;
- Process: Getting the Status of a running Process;
- Routing: URL host support in the Routing;
- Routing: Schema-relative and Path-relative URLs;
- Security: interesting security utilities;
- Validators: Payment related validators;
- FrameworkBundle: some nice performance improvement for functional tests;
- FrameworkBundle: caching for static pages.
Symfony 2.2 also comes with two new components that were extracted from existing code:
Documentation
The documentation team has been hard at work and all the new features and changes are already documented in the official documentation. It also comes with some nice new cookbooks and chapters.
Upgrading
Upgrading from 2.1 to 2.2 should be relatively easy as reported by many developers on the mailing-lists and on Twitter.
The first step is to update your `composer.json` file and run `composer.phar update`:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
diff --git a/composer.json b/composer.json
index 8f905d7..c2d7588 100644
--- a/composer.json
+++ b/composer.json
@@ -6,18 +6,18 @@
},
"require": {
"php": ">=5.3.3",
- "symfony/symfony": "2.1.*",
- "doctrine/orm": ">=2.2.3,<2.4-dev",
- "doctrine/doctrine-bundle": "1.0.*",
+ "symfony/symfony": "2.2.*",
+ "doctrine/orm": "~2.2,>=2.2.3",
+ "doctrine/doctrine-bundle": "1.2.*",
"twig/extensions": "1.0.*",
"symfony/assetic-bundle": "2.1.*",
- "symfony/swiftmailer-bundle": "2.1.*",
- "symfony/monolog-bundle": "2.1.*",
- "sensio/distribution-bundle": "2.1.*",
- "sensio/framework-extra-bundle": "2.1.*",
- "sensio/generator-bundle": "2.1.*",
- "jms/security-extra-bundle": "1.2.*",
- "jms/di-extra-bundle": "1.1.*"
+ "symfony/swiftmailer-bundle": "2.2.*",
+ "symfony/monolog-bundle": "2.2.*",
+ "sensio/distribution-bundle": "2.2.*",
+ "sensio/framework-extra-bundle": "2.2.*",
+ "sensio/generator-bundle": "2.2.*",
+ "jms/security-extra-bundle": "1.4.*",
+ "jms/di-extra-bundle": "1.3.*"
},
"scripts": {
"post-install-cmd": [
@@ -36,9 +36,12 @@
"config": {
"bin-dir": "bin"
},
- "minimum-stability": "dev",
+ "minimum-stability": "alpha",
"extra": {
"symfony-app-dir": "app",
- "symfony-web-dir": "web"
+ "symfony-web-dir": "web",
+ "branch-alias": {
+ "dev-master": "2.2-dev"
+ }
}
}
Then, read the UPGRADE document carefully and do whatever is explained there (you might also need to read the UPGRADE instructions for the Symfony Standard Edition).
Optionally, you can also make changes that will make your application more compatible with Symfony 3.0.
Installing
If you are starting a new project on Symfony 2.2, based on the full-stack framework, you have several options:
Create a new project via Composer (recommended):
1
$ php composer.phar create-project symfony/framework-standard-edition somewhere/ 2.2.0``
- Download an archive for the Symfony Standard Edition;
If you are using some of the Symfony components in your new application, just use the `2.2.0` version or the `2.2` branch:
- Via Composer packages;
- Via Github downloads: https://github.com/symfony/{COMPONENT_NAME}/archive/v2.2.0.zip;
- Via the PEAR packages (please, do me a favor and upgrade to Composer ;)).
What's next?
So, what's next? According to our release process, Symfony 2.3 will be released at the end of May 2013 and it will be the first long term support release. That's also the version that is going to be used by Drupal 8 and Laravel 4 to name just a couple of Open-Source projects that rely on the Symfony Components.
Thank you for your continued support and happy Symfony!
Help the Symfony project!
As with any Open-Source project, contributing code or documentation is the most common way to help, but we also have a wide range of sponsoring opportunities.
Comments are closed.
To ensure that comments stay relevant, they are closed for old posts.
Two things;
* "minimum-stability": "alpha", seriously?
* The Github download link template refers to the BETA1 files.
Why got this error?
I just visited the download page, prepared to skim through it to find the Composer command for 2.2 but found it presented as the canonical release. This news article confirmed it. :)
Thans all symfonysts
Something many people won't know, so I tell them:
Also new in Symfony2.2: generate:controller action in SensioGeneratorBundle! Read the docs for more information: http://symfony.com/doc/current/bundles/SensioGeneratorBundle/commands/generate_controller.html
Merci Fabien!
Would be much better to identify volatile packages and default stability of a stable release shouldn't be alpha imho. Or am I missing something?
When "stable" for "minimum stability" will be available?
It's great that you met the deadline but stable releases really should be stable.
Just in time. I upgraded my new project ))
Thanks!