Results 1 to 5 of 5

Thread: spring-ws-1.0-m2 airline sample

  1. #1
    Join Date
    Oct 2006
    Location
    Seattle, Washington, USA
    Posts
    3

    Default spring-ws-1.0-m2 airline sample

    Hi-

    I just downloaded spring-ws-1.0-m2-full.zip and while going through the airline sample code noticed that the package (and classes within) org.springframework.ws.samples.airline.schema and org.springframework.ws.samples.airline.schema.Impl are missing. FYI.

    Also, the class org.springframework.ws.samples.airline.ws.GetFligh tsEndpoint (well, the entire application) uses separate POJOs for the schema and the domain objects. It's not an architectural decision I have considered before. Can someone explain the pros of this approach over straight mapping of the domain objects? Is it a function of the XML binding framework being used?

    In advance, thanks a bunch.

    Best,
    John

  2. #2
    Join Date
    Jul 2005
    Location
    Rotterdam, the Netherlands
    Posts
    1,562

    Default

    Quote Originally Posted by jwoolf330 View Post
    I just downloaded spring-ws-1.0-m2-full.zip and while going through the airline sample code noticed that the package (and classes within) org.springframework.ws.samples.airline.schema and org.springframework.ws.samples.airline.schema.Impl are missing. FYI.
    Yes, these are generated by the build from the xsd schema.

    Quote Originally Posted by jwoolf330 View Post
    Also, the class org.springframework.ws.samples.airline.ws.GetFligh tsEndpoint (well, the entire application) uses separate POJOs for the schema and the domain objects. It's not an architectural decision I have considered before. Can someone explain the pros of this approach over straight mapping of the domain objects? Is it a function of the XML binding framework being used?
    This is by design. The danger about using your domain objects in the web service interface is that you're making them part of a public interface. That basically means that you cannot change them without changing the contract of the web service.

    So, by separating the public contract from the internal workings, you can change the two independently.
    Arjen Poutsma

    Spring Web Services Dev Lead
    Please read the FAQ

  3. #3
    Join Date
    Oct 2006
    Location
    Seattle, Washington, USA
    Posts
    3

    Default

    Thank you, Arjen.

  4. #4
    Join Date
    Dec 2006
    Posts
    2

    Default

    Quote Originally Posted by Arjen Poutsma View Post
    Yes, these are generated by the build from the xsd schema.



    This is by design. The danger about using your domain objects in the web service interface is that you're making them part of a public interface. That basically means that you cannot change them without changing the contract of the web service.

    So, by separating the public contract from the internal workings, you can change the two independently.
    Hi Arjen,

    I can't use Maven in my work environment. I tired using the XJC utility from JAXB, to generate the required source files from the airline.xsd . It did not generate the Impl files for some reason. I would appriciate it if could you help me out on this.

    By the way i am trying to run this example from within Eclipse.

    Thanks
    -Venkatesh

  5. #5
    Join Date
    Dec 2006
    Posts
    2

    Default

    Ok. I found the problem... I was using jaxb 2.0. The required files were generated when i used the 1.6 version.

Posting Permissions

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