Bo Zeng created CAMEL-17153:
-------------------------------
Summary: afterprocess of UnitOfWork doesn't work properly
Key: CAMEL-17153
URL: https://issues.apache.org/jira/browse/CAMEL-17153
Project: Camel
Issue Type: Bug
Components: came-core
Affects Versions: 3.11.3
Reporter: Bo Zeng
Fix For: 3.11.4
steps to reproduce:
Add custom UnitOfWork.
overwrite the before process and after the process, the sequence of the process
is before process-> after process -> process
expected:
before process -> process -> after process
It was working fine in 3.4. The following code adds the after process to the
last, so the process can follow the sequence.
code:
{code:java}
if (beforeAndAfter) { reactiveExecutor.schedule(()
-> { // execute any after processor work (in current thread,
not in the callback) uow.afterProcess(processor, exchange,
callback, false); }); }
{code}
Link:
[https://github.com/apache/camel/blob/6a6a8cdc0d3b146995053ce86f270df4e0956a79/core/camel-base/src/main/java/org/apache/camel/processor/CamelInternalProcessor.java#L293]
The code is removed from 3.11, so the process can't follow the sequence.
[https://github.com/apache/camel/blob/cbedd261336d576c558dcc2c4f4e358b27c9cb8f/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/CamelInternalProcessor.java#L407]
--
This message was sent by Atlassian Jira
(v8.3.4#803005)