Forum Discussion
Error - Using the MongoDB Om-Premise Connector
Before retrying:
- Database name has no dots
- Database name has no spaces
- Database name is not empty
- Database name is not the server name
- If parameterized, parameter resolves to a clean string
- vivien573 months agoSuper User
Hello Thomaslleblanc ,
Thank you for your feedback.
When you set up the connection at the gateway, you enter:
Option 1 :mongodb01.example.com:27017,mongodb22.example.com:27017,mongodb03.example.com:27017/?authMechanism=DEFAULT&authSource=xxxxxxxxx
or
Option 2:mongodb01.example.com:27017,mongodb22.example.com:27017,mongodb03.example.com:27017
By "Database name", do you mean what is specified as "AuthSource" ?
If so, in my case there’s just a “-”; the pattern is “xxxx-yyyy”
Thank in advance,
Have a nice day,
Vivien- ABD1283 months agoResolver II
Hi vivien57
The issue is likely not related to the authSource value or the hyphen in the database name. In Fabric, the Database field in the Copy activity is separate from authSource and must explicitly reference a valid MongoDB database (not blank or unresolved). The more likely issue is the connection string format and how the connector parses it during validation. I would recommend using a standard MongoDB URI format such as: mongodb://mongodb01.example.com:27017,mongodb22.example.com:27017,mongodb03.example.com:27017/?authSource=xxxx-yyyy&authMechanism=DEFAULT
Also verify that the Database field in the Copy activity is explicitly populated, URI parameters are passed using standard & separators, and, if connecting to a replica set, the replicaSet parameter may also be required depending on the MongoDB configuration.
For isolation, it may also help to test temporarily with a simplified single-node connection string.
Regards,
ABD
- vivien573 months agoSuper User
Hello ABD128 ,
Thank for your help.
With the suggested connection string, I get this error (which already seems clearer and more specific).I tried using a single-node setup, but it doesn’t work.
I’d say we’ve made some progress with the new errors, but for the moment I can’t find.
Thank in advance,
Have a nice day,
Vivien