No, this is correct. The SEI represents the portType in the WSDL, not the Service. Thus, attributes that are specific to the Service are not allowed on the SEI. That would include the serviceName and portName attributes. Those would go on the @WebService annotation on the impl itself as that represents the concrete service in the wsdl.
Dan On Tuesday, October 18, 2011 11:30:35 AM Mordecus wrote: > I've been developing a code-first WebService with CXF, version 2.4.3; > following the guidelines at > http://cxf.apache.org/docs/developing-a-service.html#DevelopingaService-Writ > ingtheinterface > > > > My SEI interface is: > > /@WebService( > name="ProvisioningOrderService", > serviceName="ProvisioningOrderService", > targetNamespace="urn:ws.thinkingphones.com:provisioningorders") > public interface ProvisioningOrderWebService { > > etc.... > > }/ > > My implementor class is: > > /@WebService(endpointInterface="com.thinkingphones.provorders.webservices.Pr > ovisioningOrderWebService" public class ProvisioningOrderWebServiceImpl > implements > ProvisioningOrderWebService{ > > etc.... > > }/ > > I've wired up the endpoint in Spring as follows: > > /<bean id="provisioningOrderService" > class="com.thinkingphones.provorders.webservices.ProvisioningOrderWebService > Impl"> <property name="addressDAO" ref="addressInfoDAO"/> > <property name="commentDAO" ref="commentDAO"/> > <property name="didRequestDAO" ref="didRequestDAO"/> > <property name="didReservationDAO" ref="didReservationDAO"/> > <property name="directoryListingDAO" > ref="directoryListingInfoDAO"/> > <property name="e911DAO" ref="e911InfoDAO"/> > <property name="provisioningOrderDAO" > ref="provisioningOrderDAO"/> > <property name="dtoMapper" ref="dtoMapper"/> > </bean> / > > /<jaxws:endpoint > id="webService" > implementor="#provisioningOrderService" > > implementorClass="com.thinkingphones.provorders.webservices.ProvisioningOrde > rWebServiceImpl" address="/ProvisioningOrderService" > />/ > > However, when I try to start the service, I get the following error: > > /Caused by: javax.xml.ws.WebServiceException: Attributes portName, > serviceName and endpointInterface are not allowed in the @WebService > annotation of an SEI. > at > org.apache.cxf.jaxws.support.JaxWsImplementorInfo.initialize(JaxWsImplemento > rInfo.java:312) at > org.apache.cxf.jaxws.support.JaxWsImplementorInfo.<init>(JaxWsImplementorInf > o.java:60) at > org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:376) at > org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:322) ... 29 > more/ > > If I take out the endpointInterface attribute from the @WebService > annotation on the ProvisioningOrderWebServiceImpl class; the webservice > starts fine. > > This makes no sense to me - it's as if CXF is incorrectly identifying the > implementor class as the actual SEI, instead of seeing it as the implementor > class. > > Any ideas? > > -- > View this message in context: > http://cxf.547215.n5.nabble.com/CXF-is-seeing-my-implementor-class-as-the-S > EI-tp4914844p4914844.html Sent from the cxf-user mailing list archive at > Nabble.com. -- Daniel Kulp [email protected] http://dankulp.com/blog Talend - http://www.talend.com
