Why I switched from ZF
Please note all the reasons I'm about to give are the reason I had at the time I quited ZF, that's like 6 months ago or so, so be aware that things may have evolved, and since this is not a rant, I won't even check if they actually changed (as I really don't give a damn). Also, I'm writing this post only because I said I'd write it, I'm not trying to convince anyone, nor am I trying to start a discussion about the pros and cons of ZF.
First, I think the Zend Framework is a bit complex. That's quite vague for a framework of that size, but let me explain. There are a lot of things to know and do before you can even think of really working on your project. Zend Framework has a lot of classes, and you better know a lot of them to get productive.
Which lead to another problem: configuration over convention. This concept is deeply rooted inside the framework, and I think it's just wrong (although I know it's a pro for some people). It forces you to know instead of just being able to guess (and I think knowing how to guess is very important for a developer), so you just can't install the framework and start working ootb, you have to read docs (well, you always have to read docs, but), you have to read A WHOLE FUCKIN LOTS OF DOCS, and god, it's boring and greatly time-consuming.
Time-consuming, because the documentation is poorly structured. I've always found it hard to find exactly what you need in the documentation. Not sure why (and that's not a point I will expand on, since this is very subjective, and most of other frameworks have equally poorly structured doc).
Now my main point: Zend Framework is nothing more than a Zend sponsored PEAR. You have no tools to ease or speed application development, no coupling between components (yet again, I know this is a pro for some people ;), no code generation, no easy database management, no task handling, etc, etc. So what's the point using a framework if he doesn't really help you developing ? Not much if you ask me (and if you're reading this, we could assume you asked).
Add to all this poorly written components (some of them don't even follow the coding standard !), stupid decisions (i18n exceptions anyone ?) and marketing-drived release policy, and there you are, one less Zend Framework enthusiast (not that it matters anyway).
So thinking about all that, there's a single word that describe exactly why I've been disappointed by ZF: expectation. Zend Framework is just not meeting my expectations, it doesn't fit my needs, that's why I switched to another framework, that, for now, I'm fully satisfied with.
Comments
Which one is your choice now?
Well I deliberately took care not to cite my new framework of choice to avoid trolling, but since you ask, I'm now using symfony.
What surprises me is that most of your grips about ZF are inherent to its main concept (glue-stack, loose coupling). This is nothing new and you could have realised that it was wrong for you a long time ago, even in the early days of the framework, since this is about concept, not implementation.
Another surprise is your point about documentation, since I would love to see in the Symfony world something like the ZF's reference guide (no, neither the "definitive guide" nor the "cookbook" are equivalents).
I'm definitly one of those that like ZF's "use at will" concept and, after all, this is also good for symfony (see "Bridges to Other Framework's Components" in symfony's doc).
Also, one thing you didn't point is ZF's lack of model validation, but then again, thanks to its modular architecture, pluging Doctrine is just a 2 lines away.
Finally, not to start a troll or something, but if I were to use a full-stack framework, I would probably use Django or Web2Py... now, that's what I call fast-development, helping frameworks, on top of a nice language, not our beloved "ugly duckling" php :-)
oh... and the part about "configuration over convention" made me smile since editing yaml configuration files is the thing I dislike the most in Symfony :-)
Mickael, you certainly have a point about the fact that I should have realised that ZF did not suit my needs earlier, I don't have much to say about that, it's all my bad.
What disturbed me the most with the documentation was the lack of search in the manual (no, there were no search at that time), and always having to endlessly browse the manual felt like a pain in the ass :-) That said, don't forget that I consider this an issue for most major frameworks I've used (including rails and symfony).
Regarding the lack of model validation, I found the Zend_Validator component quite efficient, although, as per the configuration over convention dogma, a bit boring to setup.
Finally, being far more efficient in php than in any other language, it's my language of choice for all work-related until I feel really comfortable with another language (I've been proposed python jobs for example, that I did decline because of my lack of skills in that particular language).
Yes, ZF has Zend_Validate but it's mainly used in form processing which is controller-level validation. Afaik, there is no model-level (Zend_Db_Table...) validation out of the box has seen in Doctrine.
Of course, some will argue that in modern web application design, domain model is different from database model (ie may have other data sources such as webservices, etc...), but still...
And you're right about mastering the language... it's much better to have skilled coders on poor language than poor coders on great language... it's just that I sometimes wish php was as well-designed as other languages :-) (see your post about namespace separator!)
Anyway, that was nice to you to explain your choice.
I'm not confident enough to say I'm a great developer, but I'm looking forward to be an average developer on a great language :p
Concerning your main point (why do we call this a framework?), I had *exactly* the same feeling when giving mootools a try, just after trying prototype and jquery. You ZF guys will probably love it. :]
Concerning "configuration over convention", I must say that was what I thought when testing symfony. Well, it's relative, since I come from rails, but I was quite frightened by all the things I had to do before I can just create a scaffold. It's true that it is also a good point : you can choose the components you want. But it's still "configuration over convention".
Thank you for this post, I'm completely with you. I took a different decision, I swich from PHP and ZF to Python/Django. Take a look inside, it's just wonderfull ;) (import antigravity)
kik> Did you really try symfony? Just run symfony propel:generate-admin backend MyModelName and you're done. I don't see a lot of needed configuration steps here.
@Niko : I said that I have test it, not that I spent a week learning it in depth (i don't have so much time). That means, actually, take a good tutorial, complete it, go through the API, and try to have a first impression.
Yes, i used the official symfony tutorial ("my first project") which don't mention this "generate-admin" task (don't try to make me feel gulty) and more, which features a - quite relevant for my purpose - "symfony sandbox", to get it set up quicker.
I've just seen the jobeet tutorial, it seems quite seducing. An hour per day, that's sounds good. I'll give it a try (yes, trying != testing).