FORGEBOX Enterprise 🚀 - Take your ColdFusion (CFML) Development to Modern Times! Learn More...

Ortus MongoDB Cache

v1.1.1+2600 Public

Ortus MongoDB Extension

The Ortus MongoDB Extension is a native Lucee Extension that allows your CFML server to connect to a Mongo server/cluster and leverage it for built-in caching, session storage, and NoSQL document storage.

MongoDB is a general purpose, document-based, distributed database built for modern application developers and for the cloud era. MongoDB stores data in flexible, JSON-like documents, meaning fields can vary from document to document and data structure can be changed over time. MongoDB is free to use. Versions released prior to October 16, 2018 are published under the AGPL. All versions released after October 16, 2018, including patch fixes for prior versions, are published under the Server Side Public License (SSPL) v1. Learn More


  • Lucee 5.1.0 and above
  • Mongo 4.0.X and above

Features In A Nutshell

  • Add Mongo native functionality to any Lucee server
  • Install at server level (Available to all contexts)
  • Create Cache connections in the Lucee web administrator or via Application.cfc to connect to any network-accessable Mongo cluster
  • Set and get objects from Mongo via standard CFML functions and tags (cachePut(), cacheGet(), cfcache action="get|put")
  • Fully supports all built-in Lucee cache functions including wildcard filters
  • Seamlessly distribute storage of the following to any Mongo Cluster ** Lucee session storage ** Lucee client storage ** Lucee Ram resouces (ram://...)
  • Seamlessly cache the following to any timeout-sensitive Mongo key ** Results of database queries ** Results of deterministic functions ** Complex or simple objects in your application's code ** Cached templates (cfcache action="content|cache|serverCache")
  • Extremely lightweight and fast
  • Native Mongo functions: MongoGetConnection( cacheName ), MongoGetProvider( cacheName )

Development Environment Setup

Initialize the cluster:

A Docker compose file has been set up to allow for testing the extension within a cluster of MongoDB servers. To intialize the environment for the first time, run docker-compose up -d --build

Once the containers have been built and initialized, you will need to run the following command to initialize the MongoDB cluster:

docker exec -it ortus-mongodb-lucee-extension_mongodb_1  mongo --eval 'rs.initiate({ _id: "extension_test", members: [{ _id: 1, host: "mongodb:27017" }, { _id: 2, host: "mongo-repl1:27017" }, { _id: 3, host: "mongo-repl2:27017" }], settings: { getLastErrorDefaults: { w: "majority", wtimeout: 30000 }}})'

Note: if you have cloned the repo in to a custom named directory ( e.g. named mongodb instead of ortus-mongodb-lucee-extension ), you will need to change that to your local directory name in the command above

Once the cluster is intialized you may build and deploy the extension and test by accessing



  • Adds cluster capabilities via a delimited list of hosts. A delimited list of ports or a single port may be provided


  • Adds compatibility for versions of Lucee greater than 5.2.9


  • First Version

Here are all the versions for this package. Please note that you can leverage CommandBox package versioning to install any package you like. Please refer to our managing package version guide for more information.

Version Created Last Update Published By Stable Actions
1.1.1+2600 Feb 11 2020 10:01 AM Feb 11 2020 10:01 AM
Version History
1.1.1-snapshot Jan 13 2020 04:43 PM Jan 13 2020 04:43 PM
1.1.0+2400 Dec 09 2019 10:22 AM Dec 09 2019 10:22 AM
1.1.0-snapshot Oct 08 2019 04:52 PM Oct 08 2019 04:52 PM
1.0.0+2213 Oct 08 2019 04:53 PM Oct 08 2019 04:53 PM
1.0.0-snapshot Aug 29 2019 04:12 PM Aug 29 2019 05:12 PM


  •   Ortus Solutions
  • Published
  • 1.1.1+2600 is the latest of 6 release(s)
  • Published on Feb 11 2020 10:01 AM
Add to the Lucee Admin
No collaborators yet.
  • Aug 29 2019 04:12 PM
  • Feb 11 2020 10:01 AM
  • 296
  • 283
  • 5,797