[jboss-jira] [JBoss JIRA] (WFLY-6292) A Warning should be logged if an interceptor is ignored because of missing configuration
Wolf-Dieter Fink (JIRA)
issues at jboss.org
Fri Feb 26 09:01:00 EST 2016
Wolf-Dieter Fink created WFLY-6292:
--------------------------------------
Summary: A Warning should be logged if an interceptor is ignored because of missing configuration
Key: WFLY-6292
URL: https://issues.jboss.org/browse/WFLY-6292
Project: WildFly
Issue Type: Enhancement
Reporter: Wolf-Dieter Fink
Assignee: Stuart Douglas
Every class can be used as interceptor without an annotation. The class must be listed within the ejb-jar.xml deployment descriptor.
>From the spec there are two elements in ejb-jar.xml:
<!-- definition of Iterceptor classes -->
<interceptor>
<interceptor-class>ACLASS</interceptor-class>
<!--
no around-invoke needed if the method is unique
-->
</interceptor>
</interceptors>
<!-- the binding to EJB's -->
<assembly-descriptor>
<interceptor-binding>
<ejb-name>*</ejb-name>
<interceptor-class>ACLASS</interceptor-class>
</interceptor-binding>
</assembly-descriptor>
The problem is that the <interceptor> is needed to define the interceptor class unless the class contains the @AroundInvoke annotation.
The binding need this to take effect.
The problem here is that any wrong configuration, like typo in the class name, might have the effect that the interceptor is ignored silent.
As an enhancement a WARN message should be logged that the interceptor-binding can't find the related interceptor or even a ClassNotFoundException if the class is not available.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
More information about the jboss-jira
mailing list