Skip to content
WarpStream Documentation
Start Free

warpstream kcmd

The warpstream kcmd subcommand can be used to interact with a WarpStream cluster. It provides similar capabilities as the Apache Kafka command line tools for administering a Kafka cluster.

The following table displays the available warpstream kcmd arguments. Be sure to start with the subcommand needed from the -type list below

Argument Description
-bootstrap-host

Kafka bootstrap host
Default: localhost

-bootstrap-port

Kafka bootstrap port
Default: 9092

-client-id

Client ID to pass along to WarpStream
Default: kcmd

-config-name

name of configuration to update

-config-value new configuration value to set for configuration specified by -config-name flag
-diagnose-retry-attempts

number of retry attempts for diagnose-connection
Default: 2

-group Group to perform an operation on
-key Key to use for the produced kafka records
-offset Offset to consume from (used in conjunction with the -fetch subcommand) (optional)
-partition Partition to consume from (used in conjunction with the -fetch subcommand) (optional)
-partition-count Number of partitions to create (used in conjunction with the -topic -create subcommands) (optional)
-password Password for SASL PLAIN authentication
-records Double comma (,,) separated strings to produce as records (used in conjunction with the -produce subcommand)
-scram uses scram authentication instead of the default SASL PLAIN
-timestamp list-offsets Timestamp to use for the list-offsets request type
-tls Dial with TLS or not
-tlsClientCertFile path to X.509 certificate file in PEM format for the client
-tlsClientPrivateKeyFile path to the X.509 private key file in PEM format for the client
-tlsServerCACertFile path to the X.509 certificate file in PEM format for the server certificate authority. Default will use the host’s root certificate pool
-topic Topic name
-topic-cleanup-policy

Kafka topic cleanup policy, one of: [delete, compact]
Default: delete

-type Can be one of: produce, fetch, diagnose-connection, create-topic, list-topics, delete-topic, fetch-offsets, describe-groups, broker-metadata, commit-offsets, list-groups, describe-group, list-offsets
-username Username for SASL PLAIN authentication

Diagnose Connection

warpstream kcmd -type diagnose-connection -bootstrap-host <bootstrap URL>

Create a topic

warpstream kcmd -type create-topic -topic <topic name>

Adjust topic configuration

warpstream kcmd -type alter-topic-config -topic <topic name> -config-name retention.ms -config-value 259200000

Consume from a topic

warpstream kcmd -type console-consumer -bootstrap-host <warpstream service> -topic <topic name>