Hi,
the JBoss deployer seems to suffer from a bug in JDK 1.2
For interfaces Class.getMethods() returns the bogus method <clinit>
(see Sub bug id 41444465).
This results in the following error when deploying a bean:
--- snip ---
[Container factory] java.lang.NoSuchMethodException: <clinit>
[Container factory] at java.lang.Class.getMethod0(Native Method)
[Container factory] at java.lang.Class.getMethod(Class.java:854)
[Container factory] at
org.jboss.ejb.StatelessSessionContainer.setupBeanMapping(StatelessSessionCon
tainer.java:368)
--- snip ---
Here's a possible fix:
in StatelessSessionContainer.java in method setupBeanMapping()
catch NoSuchMethodException.
It would look something like this:
if
(!m[i].getDeclaringClass().getName().equals("javax.ejb.EJBObject"))
{
try {
// Implemented by bean
map.put(m[i], beanClass.getMethod(m[i].getName(),
m[i].getParameterTypes()));
Logger.debug("Mapped "+m[i].getName()+"
"+m[i].hashCode()+"to "+map.get(m[i]));
} catch (NoSuchMethodException e)
{
// ignore bogus methods...
}
}
else
(A similar fix should be added for Stateful and Entity Beans)
Maybe somebody with commit permission can add that to CVS...
Note: I can't build with JDK 1.2 because of missing
java.lang.reflect.InvocationHandler (and other classes).
Is JBoss supposed to run with JDK 1.2?! Apparently it can only be
built with JDK 1.3?
Thanks,
Lars
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user