Skip to content

[Enhancement] Extract gRPC user-property validation hook - #11024

Open
zjncs wants to merge 1 commit into
apache:developfrom
zjncs:fix/extract-user-property-validation
Open

[Enhancement] Extract gRPC user-property validation hook#11024
zjncs wants to merge 1 commit into
apache:developfrom
zjncs:fix/extract-user-property-validation

Conversation

@zjncs

@zjncs zjncs commented Sep 5, 2026

Copy link
Copy Markdown

Fixes #11000

Extract the inline user-property validation from SendMessageActivity#buildMessageProperty into a protected checkUserProperties method. This provides a narrow override point for custom validation while preserving existing behavior.

Verification: git diff --check passed. Maven unavailable locally; CI should run proxy tests and checks. AI-assisted contribution.

Signed-off-by: zjncs <18910855655@163.com>
@zjncs
zjncs marked this pull request as ready for review September 5, 2026 09:29
Copilot AI lite review requested due to automatic review settings September 5, 2026 09:29

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@RockteMQ-AI RockteMQ-AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Summary

Clean refactoring that extracts user-property validation from buildMessageProperty into a dedicated checkUserProperties method. This improves separation of concerns and makes the validation logic reusable.

The extracted method correctly handles the max property size check and key/value validation. Minor note: ProxyConfig is read twice (once in each method), but this is negligible for a config read.

LGTM.


Automated review by github-manager-bot

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.

[Enhancement] Extract user-property validation in SendMessageActivity#buildMessageProperty into an overridable checkUserProperties method

3 participants