I'd like unbiased (if possible) opinions from Drupal developers.

I am in the (pre)process of developing a public/subscriber based tuition website that provides text and embedded (as well as downloads) video and audio content. I want to develop a community, mainly via a forum, that encourages people to help others. The members/subscribers will not be able to provide teaching material.

For me, Drupal provides everything out of the box. I have been flirting with Drupal for many months now, so understand the basics.

What concerns me, is developing bespoke modules/blocks etc. Many contributors (on the web) suggest it is difficult to 'plug-in' your own modules AND because Drupal is not OOP based (yet - v7?), any module you build could break with just a few changes in Drupal core/minor upgrades. IS THIS TRUE?

I like the Zend Framework, I could use it to 'roll-my-own', but that could mean re-inventing the wheel, for the sake of sanity re: Drupal upgrades. Plus contributed modules, are slow to upgrade. I know that is outside the control of Drupal core developers/contributors, but it is a legitimate concern never-the-less.

Pls give me your objective opinion (as much as you can with the information I have provided), as I am have a hard time making up my mind.

Comments

ceejayoz’s picture

Many contributors (on the web) suggest it is difficult to 'plug-in' your own modules

I've found it very easy to make Drupal modules. Anyone with a decent background in PHP shouldn't have much trouble doing it. It'd be a bit daunting for someone who's just starting with PHP, but that's probably true for most CMSes.

because Drupal is not OOP based (yet - v7?), any module you build could break with just a few changes in Drupal core/minor upgrades

OOP wouldn't prevent that sort of thing. Drupal is careful to not break compatibility within a release - any module you build for the 6.x branch will work in the 6.x branch. It might require some fixes if you eventually moved to Drupal 7.x, but it's generally a pretty smooth transition. Plenty of warning, too.

adub’s picture

You could look at Drupal as a publishing CMS, ZF as a web app framework - don't know if that helps.

andybrace’s picture

I agree with the first post, creating modules is relatively straightforward in drupal (there is obviously a bit of learning curve involved). I cannot compare this process with Zend Framework because I have never used it but for anyone with php experience it should be quite easy to pick up. Once you're comfortable doing this then you will start to see the benefits of drupal as a framework in it's own right.

Considering how much functionality drupal provides out the box then I'd definitely recommend building on whats there already, you could spend a massive amount of time doing this from scratch.

There is plenty of support for you when creating modules for drupal:

module developers guide:
http://drupal.org/node/508

'module builder' module - provides a blank module template that saves time when creating new modules and also gives you an overview of the various drupal hooks
http://drupal.org/project/module_builder

developer module, useful when setting up new sites and debugging new modules
http://drupal.org/project/devel

Plus theres loads of support from the drupal community.

hope this helps.

ICEcoffee-1’s picture

Thank you for your comments. I would like to disagree with one of the above threads, if I may. One of the benefits of OO is that a class can be changed and updated and this would not break an object (unless variables' scope change or methods renamed). So perhaps peoples concerns about Dupal core upgrades may have some foundation. THAT SAID, I'm grateful for the above comments, because they are similar to my current thought process. I just don't know enough about Writing Drupal modules or hooks to make a qualified decision.

I'm at the point that where I think that any disadvantages, are far outweighed by the many advantages for using Drupal, and although Drupal 7 is unlikely to move fully into the OO camp, I'm not an OO snob, I use whatever is appropriate and works.

--------

Carpet denim - Interpretation, it's a funny thing.

ceejayoz’s picture

One of the benefits of OO is that a class can be changed and updated and this would not break an object (unless variables' scope change or methods renamed).

Drupal's API functions are changed and updated all the time without breaking their functionality.

Do you have a concrete example of where Drupal's API is changing in a manner that OO would fix?

yuriy.babenko’s picture

I would say this really depends on the functionality and requirements of the project. Drupal is fantastic for a lot of things, but some features would be considerably easier to develop stand-alone, and I often find myself "breaking the rules" and throwing large amounts of complex logic into a dedicated template file for a particular page. Writing a module to handle the same functionality would often take 3-4 times longer - no thanks.

This is why I'm planning on getting familiar with CakePHP (which I've looked at and loved). I'm more of a "hand-coding" guy - I like the raw stuff, and not writing code to fit a particular CMS' style.

If you're comfortable (and have time) to do the site from scratch w/ Zend, and think that a lot of the functionality will require large module development, then go with Zend and save yourself a headache.

Pretty much anything can be done in Drupal, it's just a question of how much time you're willing to spend. Find the tipping point for you, and weigh the options accordingly.

---
Yuriy Babenko | Technical Consultant & Senior Developer
http://yuriybabenko.com

druvision’s picture

Another issue is performance.

A prospect of me asks : Can Drupal handle spikes of 50,000-100,000 people per second like Zend frameworks? Or is the pefromance of Zend Frameworks better?

I would appriciate your opinion.

Amnon
-
Professional: Drupal Development & Consulting
Personal: Hitech Dolphin: Regain Simple Joy :)

ICEcoffee-1’s picture

This is a difficult one, or should I say, not straight forward.

From my experience and a little common sense, I would say ZF has the POTENTIAL to out-perform DRUPAL. ZF allows complete freedom of which components/classes you use, and file structure, for the most part. ZF used to be resource hungry and very slow. I think there are still performance issues but only if you load 'Zend Loader'. I think the issues stem from the amount of checks it does before loading.

Drupal has decent performance out of the box, but you are not in overall control of the core system, so you have fewer options to optimise performance, though core developers are keen to keep on top of performance issues.

--------

Carpet denim - Interpretation, it's a funny thing.

Frosty1’s picture

I have built a full bore cms on the zend framework and am pretty biased that direction. I feel more comfortable working with OO PHP, and particularly with the MVC pattern. It does make things easier to maintain.

With that said I have been playing with Drupal more lately and am having a lot of fun.

In my opinion if you have a client that is going to want to play with things than Drupal is a great way to go. Same goes when you have a tight budget and need a lot of functionality programmed. On the other hand when you have a client that wants a system custom built around their specs then ZF is an amazing platform.

On a side note regarding performance, i have tested my zf based system with 100K+ pages and there is no lag. A lot of that has to do with their use of PDO i think.

jsloan’s picture

I've been a Drupal user for over 5 years. The intranet where I work has over 40 Drupal sites running on 4.7 using multi-site configuration on a Windows/Apache platform. I have developed 10+ modules specific for our intranet and have contributed bug reports/fixes back to the Drupal community. Overall, the flexibility of Drupal has made my life easier and the performance has been great!

But...
I am stuck on 4.7. It is not that I can't upgrade to 5,6, or 7, it is just not feasible for me to spend the time on the upgrades knowing that I'll have to do it again. The downside of Drupal has been the upgrades. In addition to the 10+ modules I have written I also depend on several contributed modules. The burden of migration has just become too much.

Yesterday I came upon Digitalus and I was impressed. I posted some thoughts here:The future of PHP application development . The direction you are heading is correct! I hope that you continue or that the momentum will be picked up by others that will promote the use of frameworks to produce PHP projects.

At work we have standardized on the Zend Framework for all of our new PHP development. We support Mediawiki, Wordpress, Moodle, and LimeSurvey for all of the specific wiki, blog, lms, survey requests but they are only installed and supported with no customizations! ... Our 40+ departmental sites run Drupal and will probably double in number over the next year.... but the next upgrade for our departmental web sites will be a framework that will protect our investment of development time and effort.

Proposal...
Maybe the Drupal db schema could be abstracted to a set of "models", then the community could build the "controllers" and "views" around it!

Frosty1’s picture

thanks for the input on digitalus.

one thing i would like to comment on is your concerns upgrading drupal versions.

upgrading software packages is challenging on many fronts, but consider the alternative. we have many open source solutions which are still backward compatible to PHP3 and require REGISTER_GLOBALS+++ to work. they sacrifice the security and performance so their user base does not need to update custom work.

i prefer to look at software as a living entity, something that grows over time. it takes constant tending to make it perform its best but look at it from the other perspective. ask yourself if the people who developed the software you're working with had a valid reason to make the changes they did. at least in the case of drupal and zend fw i think they usually do.

jamchange’s picture

Confess the truth,many drupal developers aren't good at php really.Isn't it?
Why I say that?
Because PHP is updated faster,but drupal's developers haven't seen the new advantage of PHP.
PHP5 ,lambda,namespace,others,PDO Module,and 'filters' module etc.
The source code of drupal looks like written by C.
Compared to Zend Framework or others Agile Develop Framework(Also Rails?),drupal has no ORM,no Configurable URL Router(register a new action,you must register a module then implement the hook_menu function,return a new assoc array.Haven't you register a module,then the module list page responses slower and slower.).Also,Drupal didn't have a decent template solution(Can you call a template customly in your code?----If you can,Tell me the way,I need it yet,^0^)
This is a great project that use C to build a large system.This is the great point of Drupal.
Confess the truth,too.I am a newer in Drupal,although I use drupal only tow months,Thanks.

thesaffyone’s picture

I have asked the same question and I think I found the answer. Drupal is great and I will be using very often for quick site development but when it comes to a totally custom solution and hacking the core then a more flexible framework is required. Zend is MVC design pattern which gives you the flexibility, example , In Drupal working with the menu system to rout the function callback, working on a node tree structure, hooking the user api while trying to understand ubercart api and also not to mention hacking the theming structure such as template or function. Basically in Drupal, you have to understand how the core themes in the system works in order to produce your own theme. Else stick with the naming and structure with little understanding to the logic behind. Modifying themes in drupal is easy enough. Adding modules is also easy compared to other content management systems. However opening the database to realize how huge it is, looking at the user interface how rich it is. Drupal is best left on how it is with little hook_api and customization of themes. If you want to be a Drupal developer then learn it all. If you want to be free then choose a web framework such as zend.
Bad points against drupal in the following:
1- It is user interface oriented “general use CMS”
2- It is complex in APIs CMF
3- It has more than you need out of the box
4- If you become module ”trigger” happy then you are risking instability
5- It is not out of the box for heavy traffic and performance based website specially drupal 7
6- It is restrictive from a design pattern MVC
7- It is not coders friendly
8- Views and CCK even though they are good for GUI, they are basically an overhead from a programming point of view, example, for each field created; a table is created in the database.
Good things about Drupal
1- It can be customized easily including theming and modules once the basic structure is understood
2- It is modular system which enables the developer to pick and select the modules needed.
3- Performance and stability can be improved via hacking the api such as cache as well as using the basic admin performance from the user interface. As well as reducing the modules used to the absolute minimum
4- It is the fastest method to produce a site
5- It has ubercart and other add ons that makes it the perfect general use website example, blogs, wiki, forum, hotel + a shopping cart
Zend is by far more powerful, efficient and expandable. Example Magneto commerce, Doctrine and plenty of third parties add ons for APIs. I have just started Zend so I am not yet in the position to give the final judgement but so far so good.

bojanz’s picture

for each field created; a table is created in the database.

Which is also what Magento does (EAV).

Also, while D7 doesn't have the most stelar performance on shared hosting, and requires knowledge to scale up, have no illusion that you will escape
such problems by going into Zend-land. A complex system is a complex system, carrying a lot of code with it, requiring investing big chunks of time, and going around quirks gathered through development. Whether it's Drupal or Magento, the basic principal is the same.

I see that some people have a clear view of Drupal's cons. However, they also have the optimism that the grass is much greener on the other side and that Zend (or any other framework) will solve the basic software world problems like performance, scalability, backwards compatibility (while having fresh APIs free of quirks). I find that amusing (as someone who came to Drupal from Zend Framework, after writing a custom Zend Framework-based CMS). Still, it's always good to have hope, even if it's hope that a silver bullet will one day appear :)