0
0
Kafkadevops~10 mins

Common connectors (JDBC, S3, Elasticsearch) in Kafka - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to specify the connector class for JDBC source.

Kafka
connector.class=[1]
Drag options to blanks, or click blank then click option'
Aio.confluent.connect.jdbc.JdbcSourceConnector
Borg.apache.kafka.connect.file.FileStreamSourceConnector
Cio.confluent.connect.s3.S3SinkConnector
Dorg.apache.kafka.connect.mirror.MirrorSourceConnector
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing a sink connector instead of a source connector.
Selecting a connector for S3 or file instead of JDBC.
2fill in blank
medium

Complete the code to specify the S3 sink connector class.

Kafka
connector.class=[1]
Drag options to blanks, or click blank then click option'
Aio.confluent.connect.elasticsearch.ElasticsearchSinkConnector
Bio.confluent.connect.jdbc.JdbcSinkConnector
Corg.apache.kafka.connect.file.FileStreamSinkConnector
Dio.confluent.connect.s3.S3SinkConnector
Attempts:
3 left
💡 Hint
Common Mistakes
Confusing S3 sink with JDBC sink.
Choosing a source connector instead of a sink.
3fill in blank
hard

Fix the error in the connector class for Elasticsearch sink.

Kafka
connector.class=[1]
Drag options to blanks, or click blank then click option'
Aio.confluent.connect.s3.S3SinkConnector
Bio.confluent.connect.elasticsearch.ElasticsearchSinkConnector
Corg.apache.kafka.connect.elasticsearch.ElasticsearchSinkConnector
Dio.confluent.connect.elasticsearch.ElasticsearchSourceConnector
Attempts:
3 left
💡 Hint
Common Mistakes
Using a source connector class which does not exist.
Using a connector class from the wrong package.
4fill in blank
hard

Fill both blanks to configure the JDBC connector to connect to a MySQL database.

Kafka
connection.url=[1]
connection.user=[2]
Drag options to blanks, or click blank then click option'
Ajdbc:mysql://localhost:3306/mydb
Bjdbc:postgresql://localhost:5432/mydb
Croot
Dadmin
Attempts:
3 left
💡 Hint
Common Mistakes
Using PostgreSQL URL for MySQL connection.
Using wrong username for MySQL.
5fill in blank
hard

Fill all three blanks to configure the Elasticsearch sink connector with topic and connection details.

Kafka
topics=[1]
connection.url=[2]
index.name.format=[3]
Drag options to blanks, or click blank then click option'
Amy_topic
Bhttp://localhost:9200
Cmy_index
Dkafka_topic
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing topic name with index name.
Using incorrect Elasticsearch URL format.