Blog > sfPropel15Plugin: It's like a new version of symfony
The Propel core team has just released the first stable version of the sfPropel15Plugin. This plugin for the symfony framework is a drop-in and backwards-compatible replacement for the core sfPropelPlugin bundled with symfony 1.3/1.4. That’s right: your existing Propel applications built with symfony can benefit from all the Propel 1.5 goodness right now, just by installing a plugin.
The plugin offers a step-by-step guide to upgrading an existing application. Basically, it’s a no-brainer, except that you mustn’t forget to replace 5 paths in the
propel.ini file with paths using the plugin. And also, rebuild your model after the upgrade, so that Propel can create the new Query classes.
What Hasn’t Changed
sfPropel15Plugin offers all the features supported by the core Propel plugin, from the YAML schema to the integration of the Propel tasks into the symfony command line. Forms and filter forms still get generated based on your model schema, ad-hoc widgets and generators are still available for foreign keys, the web debug toolbar still lists the SQL queries executed for the current request, the routing and mailer classes still work just the same as before, and the admin generator still makes it very easy to build a backend application based on a model.
In fact, using the exact same application code, sfPropel15Plugin works flawlessly, except… a little faster.
What has changed
A lot has changed under the hood, in order to take advantage of the new Query API, and to give better access to it. In fact, the list of additions is so long that it feels like a new symfony version. The plugin README lists them all, and this blog will highlight some of the new features in the near future, so for now let’s just focus on three major changes:
Admin Generator on steroids: Customize widgets and validators right from the
generator.yml, display “plain” fields like it’s symfony 1.2 again, make all columns sortable (including foreign keys and virtual columns), reduce the query count without cumbersome Peer methods, add custom filters in minutes… In short, the new
admin15theme is a fantastic productivity tool. And since it’s fully documented, you have no excuse to use the old generator theme.
Easy Relation Form Embed: Editing related objects together with the main objects (e.g., editing
Postform) is now a piece of cake. The new
sfFormPropel::embedRelation()method does all the work to fetch related objects, build the forms for each of them, and embed the related object forms into the main form. Embdeded relation forms allow to edit, add, and delete a related objects with no additional code. As a bonus, the Propel Forms documentation was rewritten from scratch, and provides many examples on how to get the best out of the Form subframework.
Core Propel Behaviors: If you rely on Propel behaviors for nested sets, slugs, soft delete, or sortable lists, then you will welcome the new core Propel behaviors, offering better performance and more features, and most of all, maintained by the Propel core team. And you will learn to love the new Concrete Inheritance behavior, which is a unique and killer feature of Propel 1.5.
It’s not just a new version of the ORM, it’s almost a new way to develop with symfony that becomes possible with sfPropel15Plugin. Say goodbye to the hard-to-learn
Criteria object and the hard-to-reuse
Peer methods, and please welcome the new generated query classes.
Built by the Propel core team with usability in mind, the plugin integrates seamlessly with the MVC framework and your existing applications. Faster, more secure, more powerful, better documented, what you’ve been expecting for a long time from Propel is finally there: a first-class ORM, fully integrated into a first-class framework.
Upgrade now, and start enjoying Propel 1.5.