-
Notifications
You must be signed in to change notification settings - Fork 51
fix(DOC-1940): clarify rpk topic consume keeps connection open #1612
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
1128095
9b69e8b
0230f08
96af7bc
2fd337c
531103e
f872e90
801b759
1354df5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,6 +7,12 @@ Consuming records reads from any amount of input topics, formats each record | |
| according to `--format`, and prints them to `STDOUT`. The output formatter | ||
| understands a wide variety of formats. | ||
|
|
||
| By default, `rpk topic consume` opens a persistent connection and waits | ||
| indefinitely for new records to arrive. It does not exit after consuming | ||
| existing records. To stop consuming, press `Ctrl+C`, or use `--num` to exit | ||
| after a fixed number of records, or specify an end offset with `--offset` | ||
| (for example, `-o start:end`). | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good call — fixed to |
||
|
|
||
| The default output format `--format json` is a special format that outputs each | ||
| record as JSON. | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: redpanda-data/docs
Length of output: 119
🏁 Script executed:
Repository: redpanda-data/docs
Length of output: 6857
🏁 Script executed:
Repository: redpanda-data/docs
Length of output: 949
Consider using more explicit documented examples for the offset specification.
The example
-o start:endis not explicitly documented in the offset table (lines 120-137) or examples section (lines 173-178). Whileendcan be used as an ending offset in ranges (as shown by-o@-1m:endin the examples), the specific patternstart:enddoesn't appear elsewhere in the documentation and lacks clear definition.Use more explicit, documented alternatives such as
-o :end(line 126: "Consume until the current end") or model after existing examples like-o@-1m:end. This improves clarity since the offset table showsendas a standalone type meaning "Consume from the end," which could confuse readers about its different meaning when used in range syntax.🤖 Prompt for AI Agents