From d089ffa2d066e609cd137288aed076d8affc0c6b Mon Sep 17 00:00:00 2001 From: Imri Paran Date: Thu, 21 Nov 2024 19:42:35 +0100 Subject: [PATCH] doc(mongodb): mongodb+srv connection scheme (#18712) - added information about the mongodb+srv connection scheme - added link to atlas guide for getting the connection string --- .../v1.6.x-SNAPSHOT/connectors/database/mongodb/index.md | 4 +++- .../v1.6.x-SNAPSHOT/connectors/database/mongodb/yaml.md | 4 +++- .../services/connections/database/mongoDBConnection.json | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/index.md b/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/index.md index fff39a3eb37..7eeef3d19b0 100644 --- a/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/index.md +++ b/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/index.md @@ -45,9 +45,11 @@ To fetch the metadata from MongoDB to OpenMetadata, the MongoDB user must have a - **Username**: Username to connect to Mongodb. This user must have access to perform `find` operation on collection and `listCollection` operations on database available in MongoDB. - **Password**: Password to connect to MongoDB. -- **Host Port**: The hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname:port`. E.g., `localhost:27017`. +- **Host Port**: When using the `mongodb` connecion schema, the hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname:port`. E.g., `localhost:27017`. When using the `mongodb+srv` connection schema, the hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname`. E.g., `cluster0-abcde.mongodb.net`. - **databaseName**: Optional name to give to the database in OpenMetadata. If left blank, we will use default as the database name. +Using Atlas? Follow [this guide](https://www.mongodb.com/docs/guides/atlas/connection-string/) to get the connection string. + {% partial file="/v1.5/connectors/database/advanced-configuration.md" /%} {% /extraContent %} diff --git a/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/yaml.md b/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/yaml.md index 85f35e9c1c4..eca206e9c88 100644 --- a/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/yaml.md +++ b/openmetadata-docs/content/v1.6.x-SNAPSHOT/connectors/database/mongodb/yaml.md @@ -74,7 +74,9 @@ This is a sample config for MongoDB: {% codeInfo srNumber=3 %} -**hostPort**: The hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname:port`. E.g., `localhost:27017`. +**hostPort**: When using the `mongodb` connecion schema, the hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname:port`. E.g., `localhost:27017`. When using the `mongodb+srv` connection schema, the hostPort parameter specifies the host and port of the MongoDB. This should be specified as a string in the format `hostname`. E.g., `cluster0-abcde.mongodb.net`. + +Using Atlas? Follow [this guide](https://www.mongodb.com/docs/guides/atlas/connection-string/) to get the connection string. {% /codeInfo %} diff --git a/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/database/mongoDBConnection.json b/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/database/mongoDBConnection.json index 7b453a16653..28113aeec7e 100644 --- a/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/database/mongoDBConnection.json +++ b/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/database/mongoDBConnection.json @@ -51,7 +51,7 @@ }, "hostPort": { "title": "Host and Port", - "description": "Host and port of the MongoDB service.", + "description": "Host and port of the MongoDB service when using the `mongodb` connection scheme. Only host when using the `mongodb+srv` scheme.", "type": "string" }, "connectionOptions": {