Docs Menu
Docs Home
/ /
MongoDB Atlas Kubernetes Operator
/

AtlasStreamConnection Custom Resource

On this page

  • Examples
  • Sample Connection
  • Change Stream Connection
  • Kafka Connection
  • Parameters

The AtlasStreamConnection custom resource configures Atlas Stream Processing connections. You can configure a sample connection, a connection to an Atlas change stream, or a connection to an Apache Kafka system.

The following examples add a connection to add to the Connections Registry of the stream processing instance. To learn more, see Manage Atlas Stream Processing.

apiVersion: atlas.mongodb.com/v1
kind: AtlasStreamConnection
metadata:
name: my-stream-connection
spec:
name: sample_stream_solar
type: Sample

Note

If you specify Sample for the spec.type parameter, the spec.name parameter must match the sample collection name. Currently, Atlas Kubernetes Operator supports only the sample_stream_solar sample collection for this custom resource.

apiVersion: atlas.mongodb.com/v1
kind: AtlasStreamConnection
metadata:
name: my-stream-connection
spec:
name: my-stream-connection
type: Cluster
clusterConfig:
name: my-cluster
role:
name: my-db-role
type: CUSTOM
apiVersion: atlas.mongodb.com/v1
kind: AtlasStreamConnection
metadata:
name: my-stream-connection
spec:
name: my-stream-connection
type: Kafka
kafkaConfig:
bootstrapServers: "comma,separated,list,of,server,addresses"
authentication:
mechanism: SCRAM-512
credentials:
name: ref-to-creds-secret
namespace: default
security:
protocol: SSL
certificate:
name: ref-to-certificate-secret
namespace: default

This section describes the available AtlasStreamConnection parameters.

spec.name

Type: string

Required

Name that identifies the stream processing connection.

Note

If you specify Sample for the spec.type parameter, the spec.name parameter must match the sample collection name. Currently, Atlas Kubernetes Operator supports only the sample_stream_solar sample collection for this custom resource.

spec.type

Type: string

Required

String that indicates the type of connection. Valid values include:

  • Sample

  • Cluster

  • Kafka

spec.clusterConfig

Type: object

Conditional

Object that contains the configuration for the connection to an Atlas change stream. If you specified Cluster for the spec.type parameter, you must specify this setting.

spec.clusterConfig.name

Type: string

Conditional

Name that identifies the connection to the Atlas change stream. If you specified Cluster for the spec.type parameter, you must specify this setting.

spec.clusterConfig.role

Type: string

Conditional

Database role for the connection to the Atlas change stream. If you specified Cluster for the spec.type parameter, you must specify this setting.

spec.clusterConfig.role.name

Type: string

Conditional

Name that identifies the database role for the connection to the Atlas change stream. If you specified Cluster for the spec.type parameter, you must specify this setting.

spec.clusterConfig.role.type

Type: string

Conditional

String that indicates the type of database role. Valid values include:

  • BUILT_IN

  • CUSTOM

To learn more, see Configure Custom Database Roles.

spec.kafkaConfig

Type: object

Conditional

Object that contains the configuration for the connection to an Apache Kafka system. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.bootstrapServers

Type: array

Conditional

Comma-separated list of server addresses for the connection to an Apache Kafka system. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.authentication

Type: object

Conditional

Object that contains the configuration for the authentication mechanism and credentials. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.authentication.mechanism

Type: string

Conditional

String that indicates the authentication mechanism for the connection to an Apache Kafka system. If you specified Kafka for the spec.type parameter, you must specify this setting. Valid values include:

  • PLAIN

  • SCRAM-256

  • SCRAM-512

spec.kafkaConfig.authentication.credentials

Type: object

Conditional

Object that contains the reference to the secret that contains the authentication credentials. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.authentication.credentials.name

Type: string

Conditional

Name of the opaque secret that contains your authentication credentials. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.authentication.credentials.namespace

Type: string

Conditional

Namespace of the opaque secret that contains your authentication credentials. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.security

Type: object

Conditional

Object that contains the configuration for the security protocol and certificate. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.security.protocol

Type: string

Conditional

String that indicates the security protocol for the connection to an Apache Kafka system. If you specified Kafka for the spec.type parameter, you must specify this setting. Valid values include:

  • PLAIN

  • SSL

spec.kafkaConfig.security.certificate

Type: object

Conditional

Object that contains the configuration for the security certificate. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.security.certificate.name

Type: string

Conditional

Name of the opaque secret that contains your secrity certificate. If you specified Kafka for the spec.type parameter, you must specify this setting.

spec.kafkaConfig.security.certificate.namespace

Type: string

Conditional

Namespace of the opaque secret that contains your security certificate. If you specified Kafka for the spec.type parameter, you must specify this setting.

Back

AtlasSearchIndexConfig