INT-2938 Filter - Provide Option for Discard
Provide an option to determine whether or not the discard (and exception throwing if configured) occurs within the advice chain (default), or after it completes. INT-2938 Filter Discard Advice Option - Schema Schema, parser, tests for option on filter element. INT-2938 Polishing - PR Comments + Doc INT-2938 Add to "What's New" INT-2938 Polishing - Javadoc Typo while merging: simplified to use boolean var only
This commit is contained in:
committed by
Mark Fisher
parent
2bf6b9ba14
commit
d1d367a97f
@@ -458,4 +458,20 @@ protected abstract Object doInvoke(ExecutionCallback callback, Object target, Me
|
||||
</para>
|
||||
</note>
|
||||
</section>
|
||||
<section id="advising-filters">
|
||||
<title>Advising Filters</title>
|
||||
<para>
|
||||
There is an additional consideration when advising <classname>Filter</classname>s. By default, any discard
|
||||
actions (when the filter returns false) are performed <emphasis>within</emphasis> the scope of the
|
||||
advice chain. This could include all the flow downstream of the <emphasis>discard channel</emphasis>.
|
||||
So, for example if an element downstream of the <emphasis>discard-channel</emphasis> throws an exception,
|
||||
and there is a retry advice, the process will be retried. This is also the case if
|
||||
<emphasis>throwExceptionOnRejection</emphasis> is set to true (the exception is thrown within the
|
||||
scope of the advice).
|
||||
</para>
|
||||
<para>
|
||||
Setting <emphasis>discard-within-advice</emphasis> to "false" modifies this behavior and the discard
|
||||
(or exception) occurs after the advice chain is called.
|
||||
</para>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
Reference in New Issue
Block a user