Announcement Announcement Module
Collapse
No announcement yet.
how to deploy Spring WS with JaxBMarshaller Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Now i am getting this error ....

    No adapter for endpoint [com.endpoint.HelloWorldMarshalledEndpoint@1e2291d]: Does your endpoint implement a supported interface like MessageHandler or PayloadEndpoint?
    I am using custom serializable object registered in marshaller as param in endpoint method.

    Done following definition in spring config xml.

    <bean class="org.springframework.ws.server.endpoint.adap ter.GenericMarshallingMethodEndpointAdapter">
    <constructor-arg ref="marshaller"/>
    </bean>



    dont know how do u register adapter for endpoint..

    help me to solve this error....

    Comment


    • #17
      In your endpoing class "HelloWorldMarshalledEndpoint", try adding the "@Endpoint" annotation before the class and "@PayloadRoot" annotations before your endpoint methods:

      Code:
      import org.springframework.ws.server.endpoint.annotation.Endpoint;
      import org.springframework.ws.server.endpoint.annotation.PayloadRoot;
      
      @Endpoint
      public class myEndPoint{
        ...
      
        @PayloadRoot(localPart = "getMyRequest", namespace = "http://localhost/ws/helloWorld/schema")
        public MyResponse getMyRequest(GetMyRequest request){
          ...
      Adjust the localPart, namespace, MyRequest, MyResponse, getMyRequest, etc for your implementation.

      Comment


      • #18
        I have already done that, according to request element of my schema i have changed local part and namespace....

        still it gives me that error.....

        and to my surprise with annotation mapping in class

        org.springframework.ws.server.endpoint.mapping.Pay loadRootAnnotationMethodEndpointMapping

        is not identifying endpoint


        instead of that

        org.springframework.ws.server.endpoint.mapping.Pay loadRootQNameEndpointMapping

        is successfully able to map to endpoint class
        .



        Also i have tried using both


        XPathParamAnnotationMethodEndpointAdapter and
        GenericMarshallingMethodEndpointAdapter


        still its not getting endpoint adapter...

        Comment


        • #19
          Hi all,

          sorry to reload this topic after 1 year .... but i have the same problem : using spring with Jaxb2marshaller and oracle oc4j ... and google didn't help me a lot ...

          does anyone solve this problem ?

          my stack trace :

          org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'webServiceTemplate' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Cannot resolve reference to bean 'jaxb2Marshaller' while setting bean property 'marshaller'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'jaxb2Marshaller' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: javax.xml.bind.JAXBContext.newInstance([Ljava/lang/ClassLjavax/xml/bind/JAXBContext;
          at org.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveReference(BeanDefinitio nValueResolver.java:275)
          at org.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveValueIfNecessary(BeanDe finitionValueResolver.java:104)
          at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.applyPropertyValues(Abs tractAutowireCapableBeanFactory.java:1210)
          at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.populateBean(AbstractAu towireCapableBeanFactory.java:978)


          Thx in advanced

          Comment


          • #20
            soap sonar

            i used "soap sonar" tool to test the webservice...just download the personal edition of the tool and open new project by giving the "wsdl" URL...thats very easy to test..

            Comment


            • #21
              Show us your jaxb2Marshaller definition in your applicationContext.xml

              Comment


              • #22
                I work on the same project as "Olivier W"

                Below the Jax2Marshaller we're using:
                Code:
                	<bean id="jaxb2Marshaller"
                		class="org.springframework.oxm.jaxb.Jaxb2Marshaller">
                		<property name="classesToBeBound">
                			<list>
                				<!-- getDetailWagonCycle -->
                				<value>be.brail.cargoweb.wagons.ws.beans.services.GetDetailWagonCycleRequest</value>
                				<value>be.brail.cargoweb.wagons.ws.beans.services.GetDetailWagonCycleResponse</value>
                			</list>
                		</property>
                	</bean>

                Comment

                Working...
                X