Skip to content
v2.278.0

MongoDbSettingsProperty Struct ​

Provides information that defines a MongoDB endpoint.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_dms as dms } from 'aws-cdk-lib';
const mongoDbSettingsProperty: dms.CfnDataProvider.MongoDbSettingsProperty = {
  port: 123,
  serverName: 'serverName',

  // the properties below are optional
  authMechanism: 'authMechanism',
  authSource: 'authSource',
  authType: 'authType',
  certificateArn: 'certificateArn',
  databaseName: 'databaseName',
  sslMode: 'sslMode',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_dms as dms

mongo_db_settings_property = dms.CfnDataProvider.MongoDbSettingsProperty(
    port=123,
    server_name="serverName",

    # the properties below are optional
    auth_mechanism="authMechanism",
    auth_source="authSource",
    auth_type="authType",
    certificate_arn="certificateArn",
    database_name="databaseName",
    ssl_mode="sslMode"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.dms.*;

MongoDbSettingsProperty mongoDbSettingsProperty = MongoDbSettingsProperty.builder()
        .port(123)
        .serverName("serverName")

        // the properties below are optional
        .authMechanism("authMechanism")
        .authSource("authSource")
        .authType("authType")
        .certificateArn("certificateArn")
        .databaseName("databaseName")
        .sslMode("sslMode")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.DMS;

var mongoDbSettingsProperty = new MongoDbSettingsProperty {
    Port = 123,
    ServerName = "serverName",

    // the properties below are optional
    AuthMechanism = "authMechanism",
    AuthSource = "authSource",
    AuthType = "authType",
    CertificateArn = "certificateArn",
    DatabaseName = "databaseName",
    SslMode = "sslMode"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

mongoDbSettingsProperty := &MongoDbSettingsProperty{
	Port: jsii.Number(123),
	ServerName: jsii.String("serverName"),

	// the properties below are optional
	AuthMechanism: jsii.String("authMechanism"),
	AuthSource: jsii.String("authSource"),
	AuthType: jsii.String("authType"),
	CertificateArn: jsii.String("certificateArn"),
	DatabaseName: jsii.String("databaseName"),
	SslMode: jsii.String("sslMode"),
}

Properties ​

authMechanismoptionalstringauth_mechanismoptionalstrauthMechanismoptionalStringAuthMechanismoptionalstringAuthMechanismoptional*string #
The authentication mechanism you use to access the MongoDB source endpoint.

For the default value, in MongoDB version 2.x, "default" is "mongodb_cr" . For MongoDB version 3.x or later, "default" is "scram_sha_1" . This setting isn't used when AuthType is set to "no" .

authSourceoptionalstringauth_sourceoptionalstrauthSourceoptionalStringAuthSourceoptionalstringAuthSourceoptional*string #
The MongoDB database name. This setting isn't used when `AuthType` is set to `"no"` .

The default is "admin" .

authTypeoptionalstringauth_typeoptionalstrauthTypeoptionalStringAuthTypeoptionalstringAuthTypeoptional*string #
The authentication type you use to access the MongoDB source endpoint.

When when set to "no" , user name and password parameters are not used and can be empty.

certificateArnoptionalstringcertificate_arnoptionalstrcertificateArnoptionalStringCertificateArnoptionalstringCertificateArnoptional*string #
databaseNameoptionalstringdatabase_nameoptionalstrdatabaseNameoptionalStringDatabaseNameoptionalstringDatabaseNameoptional*string #
The database name on the MongoDB source endpoint.
portnumberportint | floatportNumberPortdoublePort*float64 required #
The port value for the MongoDB source endpoint.
serverNamestringserver_namestrserverNameStringServerNamestringServerName*string required #
The name of the server on the MongoDB source endpoint.

For MongoDB Atlas, provide the server name for any of the servers in the replication set.

sslModeoptionalstringssl_modeoptionalstrsslModeoptionalStringSslModeoptionalstringSslModeoptional*string #