This Bash script provides a user-friendly interface for managing Debezium connectors in a Kafka Connect environment. It simplifies the process of creating, deleting, restarting, stopping, and checking the status of Debezium connectors.
- List Connectors: Display all existing connectors in the Kafka Connect cluster.
- Create Connectors: Add new connectors using JSON configuration files.
- Delete Connectors: Remove existing connectors from the cluster.
- Restart Connectors: Restart specific connectors or all connectors at once.
- Stop Connectors: Pause the operation of specific connectors.
- Check Connector Status: View the current status of a specific connector.
The script interacts with the Kafka Connect REST API to perform various operations on Debezium connectors. It uses curl
for API requests and jq
for parsing JSON responses.
Key components:
- Interactive menu for easy operation selection
- JSON file selection for connector configurations
- Error handling and user-friendly messages
- Color-coded output for better readability
- Bash shell
curl
for making HTTP requestsjq
for JSON parsing- Access to a running Kafka Connect cluster with Debezium
Run the script and follow the interactive prompts to manage your Debezium connectors.
./debezium-cli.sh