Feedback
Did this article resolve your question/issue?

   

Article

Configuring MongoDB ODBC driver to connect to multiple nodes in replica set

Information

 
TitleConfiguring MongoDB ODBC driver to connect to multiple nodes in replica set
URL Nameconfiguring-mongodb-odbc-driver-to-connect-to-multiple-nodes-in-replica-set
Article Number000110414
EnvironmentProduct: Progress DataDirect for ODBC for MongoDB driver
Version: 08.00.01.102
OS: Windows
Database: MongoDB 3.6.2
Application: All ODBC applications
Question/Problem Description
Is there any special DSN configuration with the MongoDB ODBC driver to connect to multiple nodes in replica set?
Steps to Reproduce
Clarifying Information
The MongoDB server has three nodes but if the primary IP for the HostName option is specified, the two IP addresses for the remaining two nodes cannot be specified.
There is a Read Preference option but no way to specify the secondary nodes.
Error Message
Defect Number
Enhancement Number
Cause
Resolution
During the connect process, the driver queries the server for a list of nodes in the replica set, as well as their current roles (i.e. primary or secondary). The driver uses this information to determine whether the current server meets the readPreference requirement specified by the application, or whether it needs to disconnect and reconnect to one of the other nodes in the replica set. There is no need to explicitly set the other nodes on the client side.
Workaround
Notes
References to other documentation:
Progress DataDirect for ODBC for MongoDB driver User's Guide and Reference, "Supported Features" : "MongoDB Sharding Support"
https://documentation.progress.com/output/DataDirect/odbcmongohelp/index.html#page/mongodbodbc%2Fmongodb-sharding-support.html%23

Progress DataDirect for ODBC for MongoDB driver User's Guide and Reference, "Connection Option Descriptions" : "Read Preference"
https://documentation.progress.com/output/DataDirect/odbcmongohelp/index.html#page/mongodbodbc%2Fread-preference.html%23

Progress Article(s):
Support for failover once a connection is established with MongoDB replica sets
Last Modified Date11/20/2020 7:09 AM
Files
Disclaimer The origins of the information on this site may be internal or external to Progress Software Corporation (“Progress”). Progress Software Corporation makes all reasonable efforts to verify this information. However, the information provided is for your information only. Progress Software Corporation makes no explicit or implied claims to the validity of this information.

Any sample code provided on this site is not supported under any Progress support program or service. The sample code is provided on an "AS IS" basis. Progress makes no warranties, express or implied, and disclaims all implied warranties including, without limitation, the implied warranties of merchantability or of fitness for a particular purpose. The entire risk arising out of the use or performance of the sample code is borne by the user. In no event shall Progress, its employees, or anyone else involved in the creation, production, or delivery of the code be liable for any damages whatsoever (including, without limitation, damages for loss of business profits, business interruption, loss of business information, or other pecuniary loss) arising out of the use of or inability to use the sample code, even if Progress has been advised of the possibility of such damages.