Cannot Configure MongoDB Datasource
- January 2, 2024
- 2 replies
- 3487 views
ColdFusion 2023 Licensed Standard Edition (also tried on Enterprise Edition trial).
We have a MongoDB NoSQL Database we wish to access from ColdFusion. We have a known-good connection string to the database which we can use with NoSQLBooster and MongoDBCompass on the server. What I cannot get to work is the datasource in ColdFusion. I can configure a datasource using 3rd party JDBC drivers, but these come with a hefty annual fee. ColdFusion advertises support for MongoDB, so cannot justify this unbudgeted expense.
In earlier versions of ColdFusion it was necessary to download and install MongoDB separately. I've attempted to follow the instructions to use cfpm.bat with the 'install cfmongodb' command but the server responds with 'cfmongodb (2023.0.05.330608) package is already installed'. Support for MongoDB appears to be present.
The message returned by CF Admin NoSQL Datasources is:
- Data source could not be verified. Unable to connect to the MongoDB datasource with host hkcc-pro<snip>/, port 27017. To connect successfully, enter a valid host and port
The hostname is the same as we use with NoSQLBooster and MongoDBCompas.
Can anyone provide guidance on how to get a MongoDB database configured in CF 2023?
