This is a bit of an open ended question and quite a bit of text but hang on with me.
First a little bit of background. For a last year I have been writing web services. I started with zero knowledge in this field. My job was to prepare WSDL (I could structure it however I wanted) and to implement it. I had a little influence in the way XSD Schemas were prepared but not much. I took part in 2 projects. First one had just about 5 web services, while second has more than 20 and still growing. Both undergo constant XSD Schema modifications.
Now to the point.
I decided to use two different approaches in each in terms of how I structured WSDL design. In first project I had separated the WSs between WSDLs, one WS per WSDL. This worked quite well, especially since the XSD Schemas used were different (except one basic schema that rarely changed) for each operation. You did however have 5 different WSDL, which seemed wasteful to me.
Second project had far more WSs and much larger number and more complex schemas. Here I decided to group the services into only a few WSDLs according to their use. All seemed great until I realized (big lack of knowledge on my part) that WSs, when called, are recognized by their body main element (actually I still have no idea why that is so). A lot of our WSs have the same element as input and since they are in the same WSDL, they have the same path. This caused a warning from the application server (Weblogic 10.3) but it worked. I guess it used SOAPAction header, since we're using SOAP 1.1. A problem arouse when we deployed the services on the enterprise bus (OSB). It would not work unless SOAPAction was chosen as the selection algorithm or, like our oracle advisor suggested, an additional unique element was created for each WS.
And here is the problem. How to structure the WSDL. Options I considered are:
- Choose SOAPAction header as selection algorithm. Personally I liked that solution but since SOAP 1.2 does not have it anymore, the powers that be (my boss), tells me we can't use it. I know SOAP 1.2 will have an optional "action" header but since its optional, I again can't use it (bosses reasoning: might not be in the next version at all, clients might not want to use optional feature, since its extra cost, I don't know, its a business thing).
- Use unique elements for each WS. This just looks ugly and unnecessary, but its the best we have so far.
- Go back to the previous set up and do one WS per WSDL. This is definitely least favored method. It does not feel right and from what I have read it is just bad design. But it works and gives quite a bit of flexibility.
Now, if anyone has any other solutions I would love to hear them, because this has me stumped for last month or so. I just can't find a solution that just feels right.
Thanks in advance.