Results 1 to 1 of 1

Thread: How to define a Default Endpoint

  1. #1
    Join Date
    Nov 2006
    Location
    UK
    Posts
    9

    Unhappy How to define a Default Endpoint

    Hello,

    Im fairly new to spring-ws, what Im trying to do is to setup a default endpoint for my WS to serve as the default handler to all 'stray' requests (i.e. not matching namespace and local part) but having issues setting this up. Im currently getting the following error:

    Code:
    org.springframework.ws.soap.client.SoapFaultClient Exception: No adapter for endpoint [com.xxx.DefaultEndpoint@7a5a7a5a]: Does your endpoint implement a supported interface like MessageHandler or PayloadEndpoint?

    Im confused as to what the default handler class should look like neither could find any examples on the web for this. Below is what i have currently for my default endpoint class (which is obviously doesnt work):


    Code:
    import org.springframework.ws.server.endpoint.annotation.Endpoint;
    
    @Endpoint
    public class DefaultEndpoint {
    
        public void handleDefault(){
            System.out.println("i was called....");
        }
    }
    Is there some annotation which needs to be applied to the 'handleDefault' method of the endpoint ?

    Im pretty confident that my spring configuration is correct:

    Code:
    <bean id="messageDispatcher" class="org.springframework.ws.soap.server.SoapMessageDispatcher">
            <property name="endpointMappings">
                <bean class="org.springframework.ws.server.endpoint.mapping.PayloadRootAnnotationMethodEndpointMapping">
                    <property name="defaultEndpoint">
                        <bean class="com.xxx.kms.ws.DefaultEndpoint"/>
                    </property>
                </bean>
            </property>
        </bean>
    Any ideas will be greatly appreciated!

    Cheers.
    Last edited by zzkhan; Jul 27th, 2012 at 09:47 AM. Reason: additional information

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •