Any Confluent Cloud example uses real Confluent Cloud resources that may be billable.
An example may create a new Confluent Cloud environment, Kafka cluster, topics, ACLs, and service accounts, as well as resources that have hourly charges like connectors and ksqlDB applications.
To avoid unexpected charges, carefully evaluate the cost of resources before you start.
After you are done running a Confluent Cloud example, destroy all Confluent Cloud resources to avoid accruing hourly charges for services and verify that they have been deleted.
This utility uses real Confluent Cloud resources.
It is intended to be a quick way to create resources in Confluent Cloud with correct credentials and permissions, useful as a starting point from which you can then use for learning, extending, and building other examples.
Here is a list of Confluent Cloud CLI commands issued by the utility that create resources in Confluent Cloud (function ccloud::create_ccloud_stack()
source code is in ccloud_library).
By default, the Confluent Cloud ksqlDB app is not created with ccloud-stack
, you have to explicitly enable it.
ccloud service-account create $SERVICE_NAME --description $SERVICE_NAME -o json
ccloud environment create $ENVIRONMENT_NAME -o json
ccloud kafka cluster create "$CLUSTER_NAME" --cloud $CLUSTER_CLOUD --region $CLUSTER_REGION
ccloud api-key create --service-account $SERVICE_ACCOUNT_ID --resource $RESOURCE -o json // for kafka
ccloud schema-registry cluster enable --cloud $SCHEMA_REGISTRY_CLOUD --geo $SCHEMA_REGISTRY_GEO -o json
ccloud api-key create --service-account $SERVICE_ACCOUNT_ID --resource $RESOURCE -o json // for schema-registry
# By default, ccloud-stack does not enable Confluent Cloud ksqlDB, but if you explicitly enable it:
ccloud ksql app create --cluster $CLUSTER -o json "$KSQLDB_NAME"
ccloud api-key create --service-account $KSQLDB_SERVICE_ACCOUNT_ID --resource $RESOURCE -o json // for ksqlDB
ccloud kafka acl create --allow --service-account $SERVICE_ACCOUNT_ID --operation <....> // permissive ACLs for all services