[weld-issues] [JBoss JIRA] Created: (CDITCK-76) Incorrect <servlet-name> in org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.InjectionIntoWebServiceEndPointTest.war

Jitendra Kotamraju (JIRA) jira-events at lists.jboss.org
Sun Nov 22 02:27:30 EST 2009


Incorrect <servlet-name> in  org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.InjectionIntoWebServiceEndPointTest.war
----------------------------------------------------------------------------------------------------------------------------------

                 Key: CDITCK-76
                 URL: https://jira.jboss.org/jira/browse/CDITCK-76
             Project: CDI TCK
          Issue Type: Bug
      Security Level: Public (Everyone can see)
    Affects Versions: 1.0.0.GA
         Environment: GlassFish V3
            Reporter: Jitendra Kotamraju


For org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.InjectionIntoWebServiceEndPointTest.war,  web.xml and WebService class are listed below:

<servlet>
<servlet-name>TestWebService</servlet-name>
<servlet-class>org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.SheepWSEndPoint</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>

@WebService(name="SheepWS")
public class SheepWSEndPoint {
}

There is no webservices.xml packaged in the war file and web.xml doesn't have metadata-complete attribute. From the 109 spec's point of view, annotation processing kicks in, and it will create a virtual <webservice-description> in a webservices.xml for every found @WebService in the war. For example:

<webservice-description>
...
<servlet-link>org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.SheepWSEndPoint</servlet-link>
</webservice-description>

<servlet-link> is used to find an entry in web.xml. If it doesn't find any entry, spec says to use defaults to create <servlet> entry and url-pattern mapping. Copied the spec sections at the end of this report. For example, an impl looks for the following entry in web.xml:

<servlet>
<servlet-name>org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.SheepWSEndPoint</servlet-name>
...
</servlet>

299 tck test case has a problem with the <servlet-name>. It has  "TestWebService" instead of org.jboss.jsr299.tck.tests.lookup.injection.non.contextual.ws.SheepWSEndPoint 


--------
[5.3.2.1] and [5.3.2.2] sections of JSR 109

For Servlet based endpoints using this annotation, fully qualified name of the Service Implementation Bean class
must be used as the <servlet-link> element in the deployment descriptor to map the Port component to the actual
Servlet.
Following default mapping rules apply for Web modules that contain Servlet based endpoints that use this
annotation but do not package a web.xml or a partial web.xml:
• fully qualified name of the Service Implementation Bean class maps to <servlet-name> element in web.xml.
• fully qualified name of the Service Implementation Bean class maps to <servlet-class> element in web.xml
(also specified in section 7.1.2)
• serviceName attribute of javax.jws.WebService annotation prefixed with "/" maps to <url-pattern> element
in web.xml. If the serviceName attribute in javax.jws.WebService annotation is not specified, then
the default value as specified in JSR-181 specification is used.



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the weld-issues mailing list