[
https://issues.apache.org/jira/browse/CAMEL-24929?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Claus Ibsen resolved CAMEL-24929.
---------------------------------
Fix Version/s: 4.23.0
Resolution: Fixed
The fix is merged on main, so it is in Camel 4.23.0:
* b0900b082730 CAMEL-24929: camel-core - Fix the delay pattern example in the
RedeliveryPolicy javadoc
Resolving, as the ticket was not updated when the PR was merged.
_Claude Code on behalf of Claus Ibsen_
> RedeliveryPolicy javadoc shows a malformed delayPattern example
> ---------------------------------------------------------------
>
> Key: CAMEL-24929
> URL: https://issues.apache.org/jira/browse/CAMEL-24929
> Project: Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: shashank
> Priority: Minor
> Fix For: 4.23.0
>
>
> The class javadoc of
> {{org.apache.camel.processor.errorhandler.RedeliveryPolicy}} explains the
> delay pattern with this example:
> {noformat}
> delayPattern=5:1000;10:5000:20:20000
> {noformat}
> The groups are separated by {{;}}, so the last separator should be a
> semicolon: {{5:1000;10:5000;20:20000}} (the dead letter channel docs have it
> right). Copied as is, the pattern gives a delay of 0 for the first four
> redeliveries, and the fifth redelivery fails with {{NumberFormatException:
> For input string: "5000:20:20000"}}, which replaces the original exception on
> the exchange.
> Proposed fix: correct the example in the javadoc, and add a test that the
> example gives the delays the javadoc describes (0..4 = 0, 5..9 = 1000, 10..19
> = 5000, >= 20 = 20000).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)