Announcement Announcement Module
Collapse
No announcement yet.
load context in webservice Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • load context in webservice

    Hi, i need your help again


    I want to call a webservice and there load the spring integration context for send a message by a channel.
    This is possible?
    If yes,where should i put the xml file?

    ty in advance

  • #2
    Please read the reference manual (chapter 27 which covers Web Service adapters):
    http://static.springsource.org/sprin...ce/htmlsingle/

    There are also samples for Web Services here (look first under 'basic' at the ws-inbound-gateway example):
    https://github.com/SpringSource/spri...ration-samples

    Comment


    • #3
      I readed this already but i cant understand how i generate the wsdl for client consume .... :\

      Comment


      • #4
        The Web Services support in Spring Integration builds directly upon the Spring-WS project, so please read this section of the Spring-WS manual for information about WSDL-generation:
        http://static.springsource.org/sprin...ublishing-wsdl

        I'd recommend at least browsing the rest of the Spring-WS manual as well to make sure you understand the big picture.

        Hope that helps.
        -Mark

        Comment


        • #5
          Originally posted by Mark Fisher View Post
          The Web Services support in Spring Integration builds directly upon the Spring-WS project, so please read this section of the Spring-WS manual for information about WSDL-generation:
          http://static.springsource.org/sprin...ublishing-wsdl

          I'd recommend at least browsing the rest of the Spring-WS manual as well to make sure you understand the big picture.

          Hope that helps.
          -Mark

          Thnks for the help again..
          But what i see for examples is that we always get a xml message(from SOAP protocol).
          In others frameworks we always call a method and set the paramets for the method..
          We cant do this here??

          Comment


          • #6
            Please be sure to also read the *client* sections in the Spring-WS reference manual as well as the description of the *contract first* approach.

            Comment


            • #7
              I readed all,but cant find an example that uses a "normal" method call....

              Comment


              • #8
                Well, that's where Spring Integration builds on top (internally it simply uses the WebServiceTemplate). See this sample:

                https://github.com/SpringSource/spri...Conversion.xml

                You can add a Spring Integration "gateway" element in front of the "fahrenheitChannel" so that you only need to define an interface on the client side - not even an implementation (which also facilitates testing via mocks).

                Comment


                • #9
                  Well,i think u are not understanding what i really want or im not explainig well..

                  In my side(server side) i want create a web service (method with parameters) that receive a message and send for a channel.
                  And i want to give my wsdl for client side for it call the WS...
                  Client side will not use Spring integration and i really dont want to know what he is using..What i want is just that he call my method and give parameters..

                  Comment


                  • #10
                    So, just follow the instructions on how to publish the WSDL that Mark posted in post #4 above. You just need to add a bean to the servlet context with a reference to your schema.

                    There's more detail further down in the reference that Mark suggested you read: http://static.springsource.org/sprin...-wsdl-exposure

                    Comment


                    • #11
                      Originally posted by Gary Russell View Post
                      So, just follow the instructions on how to publish the WSDL that Mark posted in post #4 above. You just need to add a bean to the servlet context with a reference to your schema.

                      There's more detail further down in the reference that Mark suggested you read: http://static.springsource.org/sprin...-wsdl-exposure

                      U mean instead of this <servlet-class> org.springframework.ws.tranport.MessageDispatchSer vvlet</servlet-class>
                      ,have the class that i want to call?

                      Comment


                      • #12
                        No; I mean follow the instructions and add a

                        Code:
                        <sws:dynamic-wsdl id="orders"
                            portTypeName="Orders"
                            locationUri="http://localhost:8080/ordersService/">
                          <sws:xsd location="/WEB-INF/xsd/Orders.xsd"/>
                        </sws:dynamic-wsdl>
                        or preferably a
                        Code:
                        <sws:static-wsdl id="orders" location="/WEB-INF/wsdl/orders.wsdl"/>
                        to the dispatcher servlet's application context.

                        Comment

                        Working...
                        X