MongoDB and Drupal (@ DrupalCon)
Last week I spent in Munich, Germany attending and speaking at DrupalCon. This was my first DrupalCon, and I have to say I was amazed with both the size (1800+ people) as well as the great community they have built. My main reason for going was to see how Drupal and MongoDB work together, and what we can do to make their integration better.
From my side, MongoDB related events were me presenting at the Munich MongoDB Usergroup on Indexing on Tuesday evening, a birds of a feather session on Wednesday, where I showed how Drupal 7 can be used with MongoDB at the moment and my presentation "Introduction to MongoDB" where I outlined what makes MongoDB such a good fit for Drupal. The presentation on the conference were standing room only.
I have taken quite a few things back from this conference. First of all, it seems clear that there is a lot of interest in the Drupal community to have MongoDB working as a first-class citizen, especially for higher traffic sites. Right now, there is a module that "just" integrates into only a few places in Drupal. We also support the EntityFieldQuery module.
But, as most of Drupal 7 is using hard coded SQL queries, it is hard (though possible) to run everything with MongoDB instead of MySQL. Due to the inherent design issues with Drupal 7 it is not easy to use and this then results that sites such as the WhiteHouse's petition website moving back from MongoDB to MySQL. In their own words:
"The current release depends on MongoDB. When we first created the application, we wanted to make sure we had a highly scalable application and database to meet our anticipated performance needs under high loads. We have been running MongoDB in production for over a year, but we have decided that the performance benefits it provides are outweighed by the complexity of trying to extend Drupal features backed by MongoDB."
Of course, we would like MongoDB to be used with Drupal and we are putting effort into making this a lot better for Drupal 8. Besides more interaction with the Drupal community such as sponsoring and attending DrupalCon, we also financially support Károly Négyesi (or chx as most people know him) to make sure that Drupal 8 will work a lot better with MongoDB. Nevertheless, there is still a lot of work to be done there.
Comments
Which is why Drupal will only be truely ready for alternative datastores once it moves to PHPCR. Right now many modules in fact only work with MySQL. Once PHPCR is put into Drupal there will be 2 key benefits:
-
there is a flexible query language to allow for advanced queries not easily captured via a plain node API
-
it will be possible to address specific performance issues at a much lower level which is encapsulated by a clear specification
As such I would highly recommend 10gen to also help out on PHPCR. While PHPCR will not become the default storage for Drupal 8, there is work underway that will enable PHPCR to be used for storage via a module. While this will not do much to boost MongoDB in the near term, it will mean that PHPCR adoption for Drupal 9 will be much more likely. But also that module developers will be more prepared for this step once it comes around.
Life Line
Created a bench and a crossing
Created 2 benches and a crossing; Updated 5 cushions, a post_box, and a crossing
Created a crossing; Updated a cushion
If you were wondering whether the www.php.net & downloads.php.net services weren't responding very well in the last 6 hours — thousands of requests/sec to https://www.php.net/ 's root.
The server's load was 720, didn't die, but CDN connections to it timed out.
Now there is a caching strategy in place for a selected set of resources.
Updated a bench
Created 3 benches; Updated 10 benches
Updated a bench
Updated a bus_stop
Created a bench and a waste_basket; Updated 6 bus_stops and a crossing
Created 2 waste_baskets and a recycling; Updated 2 bicycle_parkings and a recycling
Updated a fast_food, a funeral_directors shop, and 2 other objects; Confirmed a fast_food and a hairdresser shop
Created an information; Updated 3 benches and 2 waste_baskets
Updated 2 benches and a waste_basket
Updated a bench
Created a waste_basket and an information
Created a waste_basket
I hiked 18.0km in 4h1m52s
I walked 1.4km in 17m19s
I walked 4.5km in 1h21m49s
I just made and ate, a bowl full of bacon fried Brussels Sprouts. Not under duress, and out of my own free will.
Added new residential building
Created a hairdresser shop; Confirmed a convenience shop and a dry_cleaning shop
Created a building_materials shop, a vacant shop, and 4 other objects; Confirmed a hairdresser shop, a cafe, and 2 other objects
I walked 8.3km in 1h33m44s



Shortlink
This article has a short URL available: https://drck.me/drupalmongo-9j3