Skip to content

Conversation

@ccm32004
Copy link
Collaborator

@ccm32004 ccm32004 commented Jan 29, 2026

added method implemented to extract message metadata + junit tests to verify, update numaflow sdk, update springboot version for protobuf compatibility

Tested with streamnative pulsar cluster with consumer pipeline:

  • rebuilt image using mvn clean package
  • deleted current consumer pipeline pod corresponding to source vertex, so new pod can be created with new java pulsar container based on new updated image kubectl delete pod cloud-consumer-pipeline-in-0-xn9lh
  • checked logs in sink vertex using command kubectl logs cloud-consumer-pipeline-out-0-1o5xf -c numa --tail=20, as can be seen messages now contain extra headers with pulsar metadata
Screenshot 2026-01-29 at 10 56 35 AM

closes #51

@ccm32004 ccm32004 requested a review from KeranYang January 29, 2026 19:25
/**
* Constants for Pulsar message headers and metadata.
*/
public class Constants {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These constants are only used by consumer so let's put them under consumer folder and see if we can change the assessor level so that other pkg cannot access them. When adding a variable or method, make it as private as possible, that way we achieve the best abstraction.

Rename the class from Constants to NumaHeaderKeys which is more close to the real intent.

Comment on lines 269 to 272
Map<String, String> customProps = new HashMap<>();
customProps.put("custom-key-1", "custom-value-1");
customProps.put("custom-key-2", "custom-value-2");
customProps.put("app-version", "1.2.3");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: This new test is to verify custom properties still added to the headers. Can we merge it into the existing test case? Less boilerplate code.

Signed-off-by: Cece Ma <[email protected]>
@KeranYang KeranYang merged commit f241404 into main Jan 29, 2026
2 checks passed
@KeranYang KeranYang deleted the feature/extract-message-metadata branch January 29, 2026 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extract Additional Message Metadata as Headers

3 participants