CLI
Describes the options for the CLI K2K-Tool app
Warning: Setting offsets should only be used when the K2K application has been stopped.
If the K2K application is running, the offset reset might not be applied as the application will continue to commit offsets, potentially overwriting the reset operation.
describe
Reads the pipeline definition file(s) and displays information about the consumer group(s).
--file / -f
Comma-separated list of file(s) that define one k2k pipeline. Can be specified multiple times.
-
Yes
--defaults / -d
File containing defaults for the k2k app. Can be specified multiple times.
-
No
--template-engine / -g
Enable or disable the template engine.
enabled
No
--pull-timeout / -i
Duration after which the control topic(s) will be considered fully read if no new messages are received.
10s
No
--verbosity
Sets the log verbosity (e.g., debug, info, warn, error).
-
No
Example output:
pipeline: prod-to-stg
source: prod-cluster-id
target: stg-cluster-id
group: k2k-prod-to-stg
committed:
-
topic: user-orders
partition: 0
committed: 10
last: 20
-
topic: user-orders
partition: 1
committed: 10
last: 10
pipeline: eu-to-us
source: eu-west-1
target: us-east-1
group: k2k-cross-region-consumer-group
committed:
-
topic: telemetry-events
partition: 0
committed: 1
last: 20Examples:
set
Sets the committed offset for a consumer group to a specific offset value.
--file / -f
One or more comma-separated paths that define a single k2k pipeline.
-
Yes
--offset / -o
Offset selector in the format <topic>:<partition>:<offset>. Can be specified multiple times.
-
Yes
--defaults / -d
File containing defaults for the k2k app. Can be specified multiple times.
-
No
--template-engine / -g
Enable or disable the template engine.
enabled
No
--verbosity
Sets the log verbosity (e.g., debug, info, warn, error).
-
No
The offset selector follows the format: <topic>:<partition>:<offset>
topic: The topic name, or
*to match all topicspartition: The partition number, or
*to match all partitionsoffset: The specific offset value (numeric)
Offset Selectors:
my-topic:0:100- Set offset 100 for partition 0 of topicmy-topicmy-topic:*:100- Set offset 100 for all partitions of topicmy-topic*:0:100- Set offset 100 for partition 0 of all topics targeted by the pipeline*:*:0- Reset all partitions of all topics to offset 0 (earliest)
Examples:
reset
Resets the committed offset for a consumer group to the earliest available offset (offset 0) for all topics and partitions configured in the pipeline.
--file / -f
One or more comma-separated paths that define a single k2k pipeline.
-
Yes
--defaults / -d
File containing defaults for the k2k app. Can be specified multiple times.
-
No
--template-engine / -g
Enable or disable the template engine.
enabled
No
--verbosity
Sets the log verbosity (e.g., debug, info, warn, error).
-
No
Examples:
Last updated
Was this helpful?

