Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for MongoDB Atlas Serverless #226

Open
realugbun opened this issue Jan 26, 2022 · 0 comments
Open

Add support for MongoDB Atlas Serverless #226

realugbun opened this issue Jan 26, 2022 · 0 comments

Comments

@realugbun
Copy link

MongoDB has introduced a new serverless offering.

When the dns is queried it returns a TXT record containing authSource=admin&loadBalanced=true The loadBalanced parameter is unique to serverless so drivers that have not been updated throw an error that they get an invalid parameter from the DNS TXT record. There is no work around because as Mongo controls the DNS records.

This connection string throws an error stating "Could not open connection to database" with an explanation about the TXT record.
mongodb+srv://example.mongodb.net/test?retryWrites=true&w=majority

Caused by: com.mongodb.MongoConfigurationException: A TXT record is only permitted to contain the keys 
[authsource, replicaset], but the TXT record for 'example.mongodb.net' contains the keys [loadbalanced, authsource]
	at com.mongodb.ConnectionString.<init>(ConnectionString.java:388)
	at liquibase.ext.mongodb.database.MongoConnection.open(MongoConnection.java:104)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant