Book a Demo

Author Topic: WSDL File Comparison Problem  (Read 4020 times)

pvickers

  • EA User
  • **
  • Posts: 44
  • Karma: +7/-0
    • View Profile
WSDL File Comparison Problem
« on: June 05, 2020, 01:52:27 am »
I have a situation where an external vendor has provided my organization with a large number of updated WSDL files.
(WSDL = Web service definition files...in my situation these are WSDL version 1.1).

The files may or may not be different from an earlier collection of files.  My challenge is to perform a file comparison and determine if they are different and if so, what those differences are.

I am interested in determining any changes to the XSD structure (type information) in the WSDL files and less interested in changes to things such as service names, bindings.

I know I could simply process the files (about 80 of them) using a "diff" type of utility.  However, this is not ideal because it will simply show every minor change.
I would like to have a method of detecting structural differences such as new elements, changed element lengths, changes to optional/mandatory attributes while ignoring other changes.

I have already experimented with importing the WSDL files into EA's schema composer and using the Baseline feature.
This has not worked out for me in this situation because the import of a new WSDL file creates new internal identifiers for the various objects...even though the object names are the same...So the comparison just shows new objects rather than showing changes to existing ones based on matching their names.

I am considering writing an automated script (VBS or Javascript) or possibly using (in Python) XMLDiff.

Thanks for any ideas you can provide.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: WSDL File Comparison Problem
« Reply #1 on: June 05, 2020, 02:53:58 am »
I had a similar challenge a while ago.

compare a bunch of XSD's that were structurally different. (we went from a bunch of included xsd's to a single file per message)
We needed to know if the XSD's where functionally the same, meaning the same xml files would get validated or not validated.

I wrote a tool to do this, based on an existing xml diff library.
 https://github.com/GeertBellekens/XmlDiff

It might not work 100% in you case, but I think it might be a good start.

Geert

pvickers

  • EA User
  • **
  • Posts: 44
  • Karma: +7/-0
    • View Profile
Re: WSDL File Comparison Problem
« Reply #2 on: June 05, 2020, 03:17:16 am »
Thanks Geert!

I will check this out and give it a try.

Perry