Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are considered non-breaking or backwards-compatible changes to a WSDL contract?

This page lists the following examples:

  • Addition of new WSDL operations to an existing WSDL document
  • Addition of new XML schema types within a WSDL document that are not contained within previously existing types

But is there a definition or standard guideline for what changes are considered backwards-compatible. Or in other words, what changes can you make to your contract, and still expect not to break your clients.

like image 543
Asbjørn Avatar asked Jan 09 '12 10:01

Asbjørn


People also ask

What are backwards incompatible changes?

A non-breaking change also is known as backward compatibility. For example, newer versions of producers based on the same Business Object can be deployed without breaking existing consumers.

What is a backward compatibility issue in data analytics?

Backward compatibility (sometimes known as backwards compatibility) is a property of an operating system, product, or technology that allows for interoperability with an older legacy system, or with input designed for such a system, especially in telecommunications and computing.

What is backwards compatible Semver?

semver specifies the patch version should be updated for "backwards-compatible bug fixes." What is being considered for backwards compatibility? This could be: the documented behaviour of the system. the actual behaviour of the system.

What is backward compatibility in database?

Backward compatibility means that readers with a newer schema can correctly parse data from writers with an older schema. Forwards compatibility means that readers with an older schema can correctly parse data from writers with a newer schema.


2 Answers

I have spent some time on this particular subject, and found some guidelines in a book by Thomas Erl which I refer to at the bottom. Here is what they have to say;

Compatible Changes

  • adding a new WSDL operation definition and associated message definitions
  • adding a new WSDL port type definition and associated operation definitions
  • adding new WSDL binding and service definitions
  • adding a new optional XML Schema element or attribute declaration to a message definition
  • reducing the constraint granularity of an XML Schema element or attribute of a message definition type
  • adding a new XML Schema wildcard to a message definition type
  • adding a new optional WS-Policy assertion
  • adding a new WS-Policy alternative

Incompatible Changes

  • renaming an existing WSDL operation definition
  • removing an existing WSDL operation definition
  • changing the MEP of an existing WSDL operation definition
  • adding a fault message to an existing WSDL operation definition
  • adding a new required XML Schema element or attribute declaration to a message definition
  • increasing the constraint granularity of an XML Schema element or attribute declaration of a message definition
  • renaming an optional or required XML Schema element or attribute in a message definition
  • removing an optional or required XML Schema element or attribute or wildcard from a message definition
  • adding a new required WS-Policy assertion or expression
  • adding a new ignorable WS-Policy expression (most of the time)

There is a great book on this particular subject from Thomas Erl et al; The name is Web Service Contract Design & Versioning for SOA.

HTH.

Disclaimer: As I've mentioned, this is work done by the authors of the book and I'm merely sharing it. I'm also not affiliated in anyway; just liked the book :)

like image 193
Selim Avatar answered Oct 15 '22 20:10

Selim


Additional optional request elements (minoccurs=0) could also be backward compatible - this depends on the implementation of the service on the host side. Also, changing a mandatory response element to optional could also be backward compatible - it depends on the implementation of your client.

This area is tricky.

If you are really worried about backward compatibility consider creating a new version of the service for new clients and keep the existing implementation for existing clients. Also, in general, avoid sending domain objects over your services - use DTOs.

Hope this helps.

like image 44
Nick Ryan Avatar answered Oct 15 '22 19:10

Nick Ryan