davsclaus commented on code in PR #25742:
URL: https://github.com/apache/camel/pull/25742#discussion_r3859845907


##########
components/camel-cxf/camel-cxf-soap/src/main/java/org/apache/camel/component/cxf/jaxws/CxfConsumer.java:
##########
@@ -373,6 +379,26 @@ private void checkFailure(org.apache.camel.Exchange 
camelExchange, Exchange cxfE
             }
         }
 
+        /**
+         * Only an <em>undeclared</em> route failure is muted. An exception 
the service contract declares - annotated
+         * {@code @WebFault} - is what a SOAP client is written against, so 
suppressing it would break the contract
+         * rather than protect anything.
+         */
+        private boolean isMuted(Throwable t) {
+            return ((CxfEndpoint) getEndpoint()).isMuteException()
+                    && t.getClass().getAnnotation(WebFault.class) == null;

Review Comment:
   Minor, non-blocking: `getAnnotation(WebFault.class)` only sees the 
annotation when declared directly on the exception's own class — `@WebFault` 
isn't meta-annotated `@Inherited` in the JAX-WS spec. If a generated 
`@WebFault` exception were ever subclassed without repeating the annotation, 
muting would incorrectly apply to it. In practice CXF-generated fault classes 
are essentially never subclassed, so this is a theoretical edge case rather 
than a real risk — just flagging it for awareness, not requesting a change.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to