Federico Mariani created CAMEL-25819:
----------------------------------------
Summary: camel-core - Aggregate EIP does not recover exchanges
when the KeyValueRepository is auto-discovered
Key: CAMEL-25819
URL: https://issues.apache.org/jira/browse/CAMEL-25819
Project: Camel
Issue Type: Bug
Components: camel-core
Affects Versions: 4.23.0
Reporter: Federico Mariani
When an aggregator has no repository configured,
{{AggregateProcessor.doStart()}} auto-discovers a single {{KeyValueRepository}}
from the registry (CAMEL-24463) and assigns {{new
KeyValueAggregationRepository(kvRepo)}} directly to the field. The
{{isRecoverableRepository}} flag is only set in {{setAggregationRepository()}},
so it stays {{false}}.
As a result, for an auto-discovered repository:
* the recover checker is never scheduled
* an aggregated exchange that fails downstream is never redelivered
* its {{completed:<exchangeId>}} entry stays in the {{KeyValueRepository}}
forever
The same {{KeyValueAggregationRepository}} set explicitly with
{{aggregationRepository(...)}} recovers as expected.
Fix: use {{setAggregationRepository(...)}} in {{doStart()}}.
_Claude Code on behalf of Federico Mariani_
--
This message was sent by Atlassian Jira
(v8.20.10#820010)