Topic
6 replies Latest Post - ‏2013-03-27T07:25:02Z by SystemAdmin
V_Atvars
V_Atvars
6 Posts
ACCEPTED ANSWER

Pinned topic .NET Application web reference to SOAPInput node

‏2010-07-14T17:25:59Z |
We have developed a message flow with Message Broker 7.0 that is exposed via a SOAPInput node.

How do I develop a .Net client to consume the Web Service provide by WMB?

Can anyone suggest any resources (tutorials, redbooks, etc) that would provide suitable examples to implement this scenario?
DETAILS:

.NET Application development environment, Visual Studio, typically establishes web references by passing the service providers URL, so that it can request data contract metadata. This in turn generates proxy classes that are used to make the web service calls between client and service provider.

Obtaining the web reference metadata is normally done through a series of HTTP Get calls. But when trying to access the message flow's SOAPInput node, I get HTTP error 405:

HTTP/1.1 405 Method Not Allowed
Allow: POST, HEAD, OPTIONS
Connection: close
Content-Length: 24
Date: Tue, 13 Jul 2010 18:42:47 GMT
Server: Apache-Coyote/1.1

Unsupported Method: GET.
The consultant that developed the message flow claims that this is a limitation of Message Broker - it does not expose a queryable WSDL. Documentation suggests that I export WSDL for the message flow's message set. I have attempted to do that, but Windows SDK tool svcutil.exe is unable to successfully import the generated WSDL, throwing various errors related to invalid namespaces, WSDL bindings, and WSDL ports.

What is the proper way for a .NET application to bind to a Message Broker message flow? Should we be using some sort of different input node? Should the input node be configured somehow differently so consumable by .NET apps?
Updated on 2013-03-27T07:25:02Z at 2013-03-27T07:25:02Z by SystemAdmin
  • mgk
    mgk
    35 Posts
    ACCEPTED ANSWER

    Re: .NET Application web reference to SOAPInput node

    ‏2010-07-16T19:49:28Z  in response to V_Atvars
    Hello, WMB 7.0.0.1 now supports query WSDL.

    Kind Regards,

    MGK
    • V_Atvars
      V_Atvars
      6 Posts
      ACCEPTED ANSWER

      Re: .NET Application web reference to SOAPInput node

      ‏2010-07-19T20:18:48Z  in response to mgk
      Thanks for the suggestion.

      We applied fixpack 1 to broker, and redeployed our message flow. Unfortunatly we still are unable to query the WSDL (same HTTP 405 as before).

      Reviewing listed fixes for this update, I didn't see APAR that would have resolved this problem. Any other suggestions?
      • mgk
        mgk
        35 Posts
        ACCEPTED ANSWER

        Re: .NET Application web reference to SOAPInput node

        ‏2010-07-20T08:33:54Z  in response to V_Atvars
        Did you check the new checkbox on the 7.0.0.1 SOAPInput node called "Allow Query WSDL"?

        There is no APAR for this because it was concidered a new feature, not a defect.

        Regards,
        MGK
        • V_Atvars
          V_Atvars
          6 Posts
          ACCEPTED ANSWER

          Re: .NET Application web reference to SOAPInput node

          ‏2010-07-20T21:25:53Z  in response to mgk
          We had applied fix pack to the message broker, but not to Toolkit therefore we did not see the WSDL property. We've done that now, and can successfully query the WSDL.

          Now trying to debug a SOAP parsing exception the message flow is throwing. Are there some specific properties that need to be set a certain way in SOAPInput node so that .NET clients can consume?

          My more general question still stands as well - are there any resources available that describe how .Net apps developers should best develop clients for leveraging a MB message flow exposing a SOAP end-point?
          • V_Atvars
            V_Atvars
            6 Posts
            ACCEPTED ANSWER

            Re: .NET Application web reference to SOAPInput node

            ‏2010-07-21T20:33:40Z  in response to V_Atvars
            Some progress to report.

            Applying fixpack 1 to toolkit and broker now exposes wsdl via GET ?wsdl.

            Within Visual Studio .NET (tested with 2008 version), creation of Service reference requires you to specify the full url + ?wsdl, otherwise Visual Studio throws exceptions due to invalid method calls. For example I would enter "http:\\MessageBrokerHost:7800\myapp\myservice?wsdl". Once that is done, Visual Studio will generate the necessary proxy classes so that managed .NET code can interface with the SOAPInput node exposed by message flow.

            Ran into some issues with how SOAPInput node configured for parsing. In the messageset, the default message domain when using SOAP message domain in SOAPInput node is SOAP as well. But when trying to consume messages, I got parsing errors in mapping node trying to transform the request message body. I was able to resolve those by changing the messageset message domain to XMLNSC.

            On SOAPReply, if I tried reusing the envelope of the original request (grabbing from $LocalEnvironment/SOAP/Envelope that was populated by SOAP Extract node earlier in my flow), my .NET application couldn't parse reply. A resolved this by having the SOAPEnvelope node generate a new envelope for response.

            For the most part, I think I've resolved question but would still appreciate any additional guidance on any published references related to .NET and MB integration, if available.
          • SystemAdmin
            SystemAdmin
            4179 Posts
            ACCEPTED ANSWER

            Re: .NET Application web reference to SOAPInput node

            ‏2013-03-27T07:25:02Z  in response to V_Atvars
            Thanks for sharing your experience. Now we are able to get the response for URL?wsdl, but still we receive "Unspported Method : GET" while supplying the URL alone. Where as the .NET or J2EE based webservices provides a meaningful response.

            Can someone throw how can we make the MB webservices fully support GET method.

            Thanking in advance,
            Arul.