Capture data from Kafka platforms
Overview
You can use OCI GoldenGate to capture messages from the following streaming sources:
- Apache Kafka
- OCI Streaming
- Confluent Kafka, with or without Schema Registry
- Azure Event Hubs
- Amazon MSK
OCI GoldenGate reads messages from a Kafka topic or topics, and then converts the data into logical change records written to GoldenGate Trail files. GoldenGate Replicat processes can then use the generate Trail files to propogate data to support RDBMS implementations.
Task 1: Configure Consumer properties
- Create a Kafka Consumer properties file with one of the following deserializers
or converters. If the source is a topic in Confluent Kafka with Schema Registry,
you can use the Avro converter. For other sources, use the JSON converter or
deserializer as needed:
- Kafka Consumer properties for JSON deserializer:
key.deserializer=org.apache.kafka.common.serialization.ByteArrayDeserializer value.deserializer=org.apache.kafka.common.serialization.ByteArrayDeserializer
- Kafka Consumer properties for JSON
converter:
key.converter=org.apache.kafka.connect.json.JsonConverter value.converter=org.apache.kafka.connect.json.JsonConverter
- Kafka Consumer properties for Avro
converter:
key.converter=io.confluent.connect.avro.AvroConverter value.converter=io.confluent.connect.avro.AvroConverter
- Kafka Consumer properties for JSON deserializer:
- Save the properties file and note its location.
Task 2: Create OCI GoldenGate resources
This task guides you on how to create new resources if they don't yet exist. Ensure that the Big Data deployment you're using is upgraded to the latest version available.
Task 3: Create a credential
Before you can create the Extract, you must
first create a credential.
To create a credential:
- Select the Big Data deployment on the Deployments page.
- On the deployment details page, click Launch console.
- Log in to the Big Data deployment with the user name and password specified when you created the deployment in Task 2 Step 1.
- From the navigation menu, select DB Connections.
- On the Configuration page, under the Database tab, click Add DB
Connection (plus icon), and then complete the form as
follows:
- For Credential Domainenter
OracleGoldenGate
. - For Credential Alias, enter
kafka
. - For User ID, enter
kafka://
- For Password and Verify Password, enter a password.
- Click Submit.
- For Credential Domainenter
Task 4: Create the Extract
- On the Administration Service Overview page, click Add Extract (plus icon).
- Add an Extract with the following
values:
You return to the Administration Service
Overview page, where you can observe the Extract process start
and review event messages.