Skip to content
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

[improve][cli] Support additional msg metadata for V1 topic on peek message cmd #23978

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rdhabalia
Copy link
Contributor

@rdhabalia rdhabalia commented Feb 13, 2025

Motivation

Currently, V1 topic's CLI does not return various additional metadata (publish-time, event-time, etc,) for peek-message command. Broker already returns those additional metadata for peek-message API but CLI doesn't print it for v1 topic and it prints for v2 topic. so, this PR will make this behavior consistent between v1 and v2 topics.

Modifications

This PR doesn't make any change into API definition or its definition. it adds support of printing extra metadata while peek-message command.

Verifying this change

  • Make sure that the change passes the CI checks.

(Please pick either of the following options)

This change is a trivial rework / code cleanup without any test coverage.

(or)

This change is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

(example:)

  • Added integration tests for end-to-end deployment with large payloads (10MB)
  • Extended integration test for recovery after broker failure

Does this pull request potentially affect one of the following parts:

If the box was checked, please highlight the changes

  • Dependencies (add or upgrade a dependency)
  • The public API
  • The schema
  • The default values of configurations
  • The threading model
  • The binary protocol
  • The REST endpoints
  • The admin CLI options
  • The metrics
  • Anything that affects deployment

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

Matching PR in forked repository

PR in forked repository:

@rdhabalia rdhabalia added area/cli doc-not-needed Your PR changes do not impact docs ready-to-test labels Feb 13, 2025
@rdhabalia rdhabalia self-assigned this Feb 13, 2025
@codecov-commenter
Copy link

codecov-commenter commented Feb 14, 2025

Codecov Report

Attention: Patch coverage is 11.11111% with 32 lines in your changes missing coverage. Please review.

Project coverage is 74.26%. Comparing base (bbc6224) to head (83e8509).
Report is 919 commits behind head on master.

Files with missing lines Patch % Lines
...in/java/org/apache/pulsar/admin/cli/CmdTopics.java 8.57% 30 Missing and 2 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #23978      +/-   ##
============================================
+ Coverage     73.57%   74.26%   +0.69%     
+ Complexity    32624    31903     -721     
============================================
  Files          1877     1853      -24     
  Lines        139502   143813    +4311     
  Branches      15299    16333    +1034     
============================================
+ Hits         102638   106804    +4166     
+ Misses        28908    28626     -282     
- Partials       7956     8383     +427     
Flag Coverage Δ
inttests 26.74% <0.00%> (+2.16%) ⬆️
systests 23.23% <0.00%> (-1.10%) ⬇️
unittests 73.80% <11.11%> (+0.95%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...g/apache/pulsar/admin/cli/CmdPersistentTopics.java 70.18% <100.00%> (+4.65%) ⬆️
...in/java/org/apache/pulsar/admin/cli/CmdTopics.java 80.54% <8.57%> (-0.64%) ⬇️

... and 1037 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cli doc-not-needed Your PR changes do not impact docs ready-to-test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants