[
https://issues.apache.org/jira/browse/CAMEL-23494?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Federico Mariani updated CAMEL-23494:
-------------------------------------
Description:
When preparingShutdown was introduced in the shutdown strategy (CAMEL-3364),
the resume path was not updated to clear the flag on error handlers. The
CAMEL-23310 fix added doResume() reset logic to all three affected error
handlers, but doResume() is never called because error handlers are excluded
from the service list used during resume
(getChildServices(includeErrorHandler=false)).
[#camel > Context.suspend+resume on transacted route always rollback @
💬|https://camel.zulipchat.com/#narrow/channel/257298-camel/topic/Context.2Esuspend.2Bresume.20on.20transacted.20route.20always.20rollback/near/583814141]
*Steps to reproduce:*
{code:java}
// any transacted route
from("direct:start").transacted().process(e -> db.insert(...));
// send first message — commits
template.sendBody("direct:start", "first"); // row count = 1
// suspend and resume
context.suspend();
context.resume();
// send second message — silently rolled back
template.sendBody("direct:start", "second"); // row count still 1, expected 2
{code}
was:
When preparingShutdown was introduced in the shutdown strategy (CAMEL-3364),
the resume path was not updated to clear the flag on error handlers. The
CAMEL-23310 fix added doResume() reset logic to all three affected error
handlers, but doResume() is never called because error handlers are excluded
from the service list used during resume
(getChildServices(includeErrorHandler=false)).
[#camel > Context.suspend+resume on transacted route always rollback @
💬|https://camel.zulipchat.com/#narrow/channel/257298-camel/topic/Context.2Esuspend.2Bresume.20on.20transacted.20route.20always.20rollback/near/583814141]
> preparingShutdown flag not reset on error handlers after suspend/resume —
> causes silent transaction rollback and redelivery suppression
> ---------------------------------------------------------------------------------------------------------------------------------------
>
> Key: CAMEL-23494
> URL: https://issues.apache.org/jira/browse/CAMEL-23494
> Project: Camel
> Issue Type: Bug
> Affects Versions: 4.20.0
> Reporter: Federico Mariani
> Assignee: Federico Mariani
> Priority: Major
>
> When preparingShutdown was introduced in the shutdown strategy (CAMEL-3364),
> the resume path was not updated to clear the flag on error handlers. The
> CAMEL-23310 fix added doResume() reset logic to all three affected error
> handlers, but doResume() is never called because error handlers are excluded
> from the service list used during resume
> (getChildServices(includeErrorHandler=false)).
> [#camel > Context.suspend+resume on transacted route always rollback @
> 💬|https://camel.zulipchat.com/#narrow/channel/257298-camel/topic/Context.2Esuspend.2Bresume.20on.20transacted.20route.20always.20rollback/near/583814141]
> *Steps to reproduce:*
> {code:java}
> // any transacted route
> from("direct:start").transacted().process(e -> db.insert(...));
> // send first message — commits
> template.sendBody("direct:start", "first"); // row count = 1
> // suspend and resume
> context.suspend();
> context.resume();
>
> // send second message — silently rolled back
> template.sendBody("direct:start", "second"); // row count still 1, expected
> 2 {code}
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)