- Difficult to learn
- High database load
- Illiterate structure
- Lack of OOP
- Strange cache
- Module incompatibility
- Laborious customization
In principle, you can not read further, since it will be the same, but in detail.
Prehistory
Three months have passed since I started learning Drupal. In the process of studying, I read the books “Building Powerful and Robust Applications with Drupal 6”, “Learning Drupal 6 module development” and “Pro Drupal Development. 2nd Edition ”, also during the use often had to refer to the documentation of Drupal and its API. Somewhere in late September, I gave a lecture on “Drupal” at a webinar at my home university, where I talked about what Drupal is, what it can and what I have already learned to do in it.
In many sources I stumbled upon phrases and diagrams, the essence of which boiled down to the fact that here's a little bit more and Drupal would become just an ideal means for developing ... It didn’t wait, it got tired!
Basic problems
Already when I read the report at the seminar, I highlighted a couple of Drupal problems that many people write and talk about: the complexity of the study and the high load on the database. There was a person on my report who had already managed to tinker with him for about a year before and disliked him very much. He said that the load on the database is almost the worst parameter of Drupal, in which it loses to almost everyone. And all the beautiful numbers about a large number of users are exaggerated, but in reality Drupal can hold no more than 1000 visitors per day. He only laughed at my remark about drupal.org, saying that drupal.org already had so many patches stuffed with it that only the name of the drupal remained in it.
')
But I had to finish the project on Drupal and therefore had to continue fluttering. As I went deeper, I began to notice that there were far more problems in Drupal than it seemed to me when I gave a talk. The first and most sometimes out of the rut became Drupal's cache. I still do not understand how it works. For example, I change the function in the module, and it may or may not be executed. This is all despite the fact that all cache settings accessible from the admin interface were turned off. The situation is even worse with the addition and removal of functions in the module. If, while adding, sometimes it is enough just to update the “favorite” cache, then when removing some function, sometimes fatal error pops up. It is not always possible to treat it, and it is often necessary to remove all cache data from the database with pens.
Looking ahead, I will say that in Symphony, which I am currently studying, this problem does not exist. It has Environment's (in Russian it probably will be “environments”, but maybe it is officially translated wrong, correct, if that!), Roughly speaking, each environment is a specific site configuration. By default, there are dev and prod environments (there is also a test, if that), respectively, development and production (ie, the development and release environments). In dev'e, almost all caching is disabled, and you don’t have to tear your hair out of yourself, trying to guess what happened: a syntax error or the cache was not updated.
The retreat that takes place: In general, probably, neither what was said above, nor what was said below can be the only true truth. In my case, the negative with Drupal is also related to some of the factors that accompanied it: I began to study Drupal 6, in which few books are currently written, and some of the documentation is written on the basis that you are already familiar with Drupal 5; I have not studied the book to the end, because suddenly the project came over, and it was not up to in-depth picking.
The second problem of Drupal is the customization of templates. It seemed to me like this: it gives a set of variables that need to be inserted into the appropriate places in the layout. But it turned out to be not so. First of all, each Drupal module can and gives its html code, which often does not suit me. Despite the fact that Drupal has so-called theme functions (ie, the possibility of overloading standard output), it is not always so easy to get to them, because secondly, sometimes by the time the final function starts (ie, functions which gives the content) part of the html'a already sitting in the variables. Well and thirdly, where was it seen that html was given from the function? The result is an absolutely unreadable code.
A separate word should be said about the modules in Drupal. The standard module has the following structure:
- module_name.info ( the module info is stored here )
- module_name.install ( here is stored info how to install the module )
- module_name.module (the module code is stored here; ALL! )
The size of the file module_name.module ranges from 1 to 109 (in my case) kilobytes. In the case of the most terrible and huge file, this is 3000 lines of code. Is it possible to read and / or manage such code? And such a structure is adopted by the standard for this CMF'ki.
Dig deeper
This is only the beginning of the problems that lurked me in the way of working with Drupal. The next problem was the incompatibility of the modules. It is clear that to expect compatibility from modules that are written by the pioneers and not recommended by the community is not worth it. But I put quite fulfilled and proven modules:
- Devel - a set of utilities for developers (Devel from Development), in particular, implements a cache clear button in the menu (see above why it is needed)
- FCKeditor - WYSIWYG Editor
- TinyMCE is another WYSIWYG editor, why do I need two of them below
- Localization Client is a convenient Ajax client for localizing the interface, because Drupal has no normal translation into Russian.
- Ubercart - online store
The first incompatibility was revealed between FCKeditor and Localization Client. If the page had two or more textarea, into which you need to insert an editor, then the page began to be capricious and refused to persist. Well, I put TinyMCE, but with all my love for this editor, I could not get it to work in the part of administering the site. Because it is not configured as FCKeditor. In order to enable TinyMCE, you need to specify the path of the page on which the editor will be visible. And FCKeditor is configured by id'shnikam textarea. As a result, I have FCK in one part and TinyMCE in the other. Unfortunately, TinyMCE also had to be left because the module for inserting images that can resize them (the Imagepicker) only works with it.
Devel, which everyone loves very much, also later threw out incompatibility with Ubercart, killing the whole project on the categories page of the online store.
Drupal is not for developers
Finally, I decided to get rid of using Drupal by getting acquainted with symfony. As a developer who likes to create, in Drupal, most of the time I tried to tighten the bolts of a bicycle so that it had a third wheel spinning and the chain was made of platinum. Also, I really don't like the fact that despite the fact that version 6 was released this year, it does not even smell the PLO. The developers explain it very simply, literally the following:
"Yes, there is no OOP in Drupal, but many of its principles have been implemented by us, and in principle you will feel free." But the difference is still very tangible. Otherwise, why would you need to use a calculator, because the accounts have long been invented!
But it is not all that bad
Practice shows that the medal has two sides. If everything were so bad, then no one would have used such a bad thing as Drupal, but they did. Drupal is well suited for those who need to quickly deploy a powerful resource, such as Habra (see the example of Shvarashvabra) as soon as possible, without being too bothered with customization and their features. But you need to be prepared that, going beyond the limits of the functions of the modules used, you will encounter problems, some of which I described above.
This article is the personal opinion of the author about CMF Drupal, as well as a summary of the experience with him. Do not kick if offended anyoneupd: Thanks for the plus in karma, a little bit was enough to transfer to the Drupal blog
upd2: I found that I lied a little in the phrase
The first incompatibility was revealed between FCKeditor and Devel , there is not Devel, but Localization Client. I apologize!