From: Thomas Diesler [mailto:thomas.diesler@redhat.com]
Sent: Friday, November 17, 2006 7:44 AM
To: Jason T. Greene
Cc: Heiko Braun; jbossws-dev(a)lists.jboss.org
Subject: Re: [jbossws-dev] JSR181 Changes added in async changes
-snip-
>
>The spec requires you to specify endpointInterface using a string! So
a
>simple refactor moving the interface would break the WS
deployment.
@WebService (endpointInterface = MySEI.class.getName())
Yes although in that case the spec should have defined the value as a
Class instead of a string (just like @Remote).
>Also, it's normal java practice to actually implement the
interface.
So
>the information for which interface to use is right there, in the
>implements line. Further, if someone doesn't specify endpointInterface
>by accident, and yet they do implement the endpointInterface, then it
>will be ignored but the deployment will still work (since the bean
class
>is used). However, this will be confusing to the user, because
they
will
>potentially get different output since all of the specialized
>annotations are on the interface.
The deployment should fail because there is no @WebMethod on the bean
Actually, according to the spec the lack of @WebMethod annotations
result in all methods being added, and all super class methods being
added. This weird behavior lead to @WebMethod(exclude = "true").
-Jason
-----Original Message-----
From: Thomas Diesler [mailto:thomas.diesler@redhat.com]
Sent: Friday, November 17, 2006 2:17 AM
To: Jason T. Greene
Cc: Heiko Braun; jbossws-dev(a)lists.jboss.org
Subject: Re: [jbossws-dev] JSR181 Changes added in async changes
IMO this is fuzzy logic and should be avoided.
There should at least be a comment that states the compelling reason
to
do this guess-work.
Jason T. Greene wrote:
Heiko,
I noticed the following change, which adds some non spec compliant
behavior. I am not against it, but we probably should all discuss
this
further before we decide to do it. Do you have anything right now
that
depends on it?
Also, it breaks the JSR181HandlerTestCase (although I will change
the
test in the mean time)
if (anWebService.endpointInterface().length() > 0)
{
seiName = anWebService.endpointInterface();
seiClass = udi.classLoader.loadClass(seiName);
anWebService =
(WebService)seiClass.getAnnotation(WebService.class);
+
if (anWebService == null)
throw new WSException("Interface does not have a
@WebService annotation: " + seiName);
}
+ else
+ {
+ WebService seiAnnotation = null;
+
+ for(Class potentialSEI : sepClass.getInterfaces())
+ {
+
if(potentialSEI.isAnnotationPresent(WebService.class))
+ {
+ seiClass = potentialSEI;
+ seiName = seiClass.getName();
+ seiAnnotation =
sepClass.getAnnotation(WebService.class);
+ break;
+ }
+ }
+
+ if(seiAnnotation!=null)
+ anWebService = seiAnnotation;
+ }
+
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Jason T. Greene
Senior Software Engineer
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
_______________________________________________
jbossws-dev mailing list
jbossws-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jbossws-dev
--
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Thomas Diesler
Web Service Lead
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
--
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Thomas Diesler
Web Service Lead
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx