Hi,
While trying to deploy seam's booking sample I run across the class -
org.apache.openejb.core.interceptor.ReflectionInvocationContext and
its method getParameters(). It throws the ISE exception when an
interceptor gets at the parameters of the method it intercepts. See
line 69.
public Object[] getParameters() {
if (operation.isCallback()) {
throw new IllegalStateException("Callback methods cannot
access parameters");
}
return parameters.clone();
}
Why is that? According to the EJB 3.0 spec - 12.5 InvocationContext p. 308:
The getParameters method returns the parameters of the business method
invocation. If setParameters
has been called, getParameters returns the values to which the
parameters have been
set. The setParameters method modifies the parameters used for the
business method invocation.
Modifying the parameter values does not affect the determination of
the business method that is invoked
on the bean class. The parameter types must match the types for the
business method, and the number of
parameters supplied must equal the number of parameters the business
method, or the IllegalArgument-
Exception is thrown.
So, it's allowed. Why is it not in openejb3? I had to disable seam's
interceptors to pass the check.
Jacek
--
Jacek Laskowski
http://www.JacekLaskowski.pl