Announcement Announcement Module
No announcement yet.
One Endpoint two Inputs... Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • One Endpoint two Inputs...

    I'd like to have one endpoint; call it the CurrencyExchangeEndpoint. I'd like to have this one endpoint support both SOAP and POX requests in one deployment.

    I know from the reference docs that I can change my MessageFactory from the SaajSoapMessageFactory to the DomPoxMessageFactory to support the POX use case.

    Well the problem with that is that the MessageDispatcherServlet only supports using one WebServiceMessageFactory. This makes for a really unfortunate arrangement where I have to put up two MessageDispatcherServlets so that they can work on separate WebServiceMessageFactories.

    I'd like to see the MessageDispatcherServlet (since it is following the Spring MVC design) to follow the URL HandlerMapping stuff that Spring MVC uses.

    That way you can decide which WebServiceMessageFactory to use based on the incoming url, the same way Spring MVC routes requests to Controllers.

    Or is there a better way that I'm missing, and all this typing merely results in a few minutes of my life I won't get back?

  • #2
    Is having two MessageDispatcherServlets the only way to accomplish then?


    • #3
      Yes, I think you need to use two servlets. But you can put the shared components (endpoints, endointmappings) in a separate file in WEB-INF, and import that into the two servlet contexts.