kafkactl icon indicating copy to clipboard operation
kafkactl copied to clipboard

Timestamp based consumption

Open nanic opened this issue 2 years ago • 2 comments

Description

The fix provides with a new config option to consume from timestamp and also an optional end timestamp.

Fixes #121 (issue)

Type of change

Please delete options that are not relevant.

  • [ ] New feature (non-breaking change which adds functionality)

Documentation

  • [ ] a usage example was added to README.md

nanic avatar May 11 '22 21:05 nanic

Hey @nanic thank you for the PR. Can you please add tests for your change? Have a look here: https://github.com/deviceinsight/kafkactl/blob/main/.github/contributing.md#testing-your-changes

You can probably derive your tests from one of the other tests in https://github.com/deviceinsight/kafkactl/blob/main/cmd/consume/consume_test.go

d-rk avatar May 12 '22 06:05 d-rk

1 Question, 1 error:

  1. Why "--exit" would be mandatory when using "--from-timestamp"? It should be allowed but optional.
  2. When using "--end-timestamp", using "--exit" does not make any sense.

The consumer can start consuming from a particular timestamp and it is supposed to be used in tandem with --exit e.g.: kafkactl consume my-topic --from-timestamp --exit

There is an optional parameter to give end timestamp e.g.: kafkactl consume my-topic --from-timestamp --end-timestamp --exit

pierre-degrandmaison avatar Jun 13 '22 14:06 pierre-degrandmaison

closed in favor of the more complete PR https://github.com/deviceinsight/kafkactl/pull/147

d-rk avatar Mar 06 '23 06:03 d-rk