Hardware and performance

Problems with MongoDB for application cache?

Picture of Colin Campbell
Problems with MongoDB for application cache?
Group Core developers

We have a large Moodle installation with eight app servers.  We are now getting our Moodle 2.6 instance ready to handle Fall semester loads.  Does anybody have any positive or negative experiences using MongoDB for the MUC application cache that they can share?

I expect other large installation are facing a similar situation to this:  We learned with 2.4 that an NFS file store is not usable as an application cache.  Consequently, we moved to memcache.  The problem with memcache now is that many parts of Moodle 2.6 are using the MUC application cache.  I just counted 17.  If any one of those 17 decides to purge its cache that purge causes the entire memcached instance to purge.  This is resulting in a purge frequency that will likely be very bad for performance in the Fall.  (This memcache purge problem is the subject of MDL-45375, but think that ticket understates the impact.)

Continuing to rely on memcache for the application cache would involve setting up separate memcached instances (that is, separate server-ports) for every one of those 17 application caches.  Conceivably, we could analyze them all and determine which could coexist because they are never purged on their own, but that would require a significant analysis effort for an unknown payback.

To avoid this problem, we are now going down the MongoDB path for the application cache and would appreciate learning about any pitfalls or suggestions from others who have gone down this path.

Average of ratings:Useful (1)