Skip to content

[studio][ISSUE #10904] Tolerate malformed Proxy retry counters - #10905

Draft
messere1 wants to merge 1 commit into
apache:developfrom
messere1:codex/studio-10904-malformed-retry-counters
Draft

[studio][ISSUE #10904] Tolerate malformed Proxy retry counters#10905
messere1 wants to merge 1 commit into
apache:developfrom
messere1:codex/studio-10904-malformed-retry-counters

Conversation

@messere1

Copy link
Copy Markdown

What changed

  • tolerate malformed reconsume-times values and keep the existing default of 0
  • tolerate malformed max-reconsume-times values and leave the optional header field unset
  • continue clearing both internal retry properties after handling them
  • add a regression test for both malformed counters

Why

ProducerProcessor parsed both retry counters with Integer.valueOf. A malformed stored property raised NumberFormatException while building the broker request header and aborted Proxy message forwarding. The same method already handles a malformed born timestamp defensively.

Impact

Valid retry messages keep their current request-header values. Only malformed counters use safe defaults; no public API changes are introduced.

Fixes #10904

Validation

  • mvn -pl proxy -Dtest=ProducerProcessorTest -Djacoco.skip=true test
    • 7 tests, 0 failures, 0 errors
    • Checkstyle: 0 violations
    • SpotBugs: 0 issues

JaCoCo is skipped locally because the repository's JaCoCo 0.8.5 agent does not support Java 17 class files.

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.

[studio][Bug] Malformed retry counters can abort Proxy message forwarding

1 participant