Proposal: collapse binding namespaces

This proposal follows the last discussion at yesterday's F2F in which
Glen suggested putting each binding into its own namespace. Note that
only the XML syntax and WSDL infoset are impacted: the component model
remains unchanged.


Template Driven Syntax
----------------------

WSDL provides a syntax framework for each binding to extend in its own
binding specific namespace. Each binding has to populate the common binding
component model, so it made sense for WSDL to provide the common XML syntax
to achieve this. e.g. the SOAP 1.2 binding[1] :

  <binding name="xs:NCName" interface="xs:QName"? >
    <documentation />?

    <wsoap:binding protocol="xs:anyURI"
                   mepDefault="xs:anyURI"?
                   webMethodDefault="xs:string"? />

    <wsoap:module uri="xs:anyURI" required="xs:boolean"? >
      <property ... />?
    </wsoap:module>*

    <wsoap:header element="xs:QName" />*

    <feature ... />*
    <property ... />*

    <fault ref="xs:QName"
      wsoap:code="xs:QName"
      wsoap:subcodes="list of xs:QName" />
      <documentation />?
    </fault>*

    <operation ref="xs:QName" >
      <documentation />?

      <wsoap:operation mep="xs:anyURI"?
                       webMethod="xs:string"?
                       action="xs:anyURI"? />?

      <input messageLabel="xs:NCName"? >
        <documentation />?
        <wsoap:module ... />*
        <wsoap:header ... />*
        <feature ... />*
        <property ... />*
        <fault ... />*
      </input>*

      <output messageLabel="xs:NCName"? >
        <documentation />?
        <wsoap:module ... />*
        <wsoap:header ... />*
        <feature ... />*
        <property ... />*
        <fault ... />*
      </output>*
    </operation>*

  </binding>

Processing the binding at the XML level could be simplified by
putting the whole binding in a single binding specific namespace:


 <binding name="xs:NCName" interface="xs:QName"? >
    <documentation />?

    <binding protocol="xs:anyURI"
                   mepDefault="xs:anyURI"?
                   webMethodDefault="xs:string"?
          xmlns="http://www.w3.org/2003/11/wsdl/soap12">

    <module uri="xs:anyURI" required="xs:boolean"? >
      <property ... />?
    </module>*

    <header element="xs:QName" />*

    <feature ... />*
    <property ... />*

    <fault wsoap:ref="xs:QName"
      code="xs:QName"
      subcodes="list of xs:QName" />
      <documentation />?
    </fault>*

    <operation ref="xs:QName" >
      <documentation />?

      <operation mep="xs:anyURI"?
                       webMethod="xs:string"?
                       action="xs:anyURI"? />?

      <input messageLabel="xs:NCName"? >
        <documentation />?
        <module ... />*
        <header ... />*
        <feature ... />*
        <property ... />*
        <fault ... />*
      </input>*

      <output messageLabel="xs:NCName"? >
        <documentation />?
        <module ... />*
        <header ... />*
        <feature ... />*
        <property ... />*
        <fault ... />*
      </output>*
    </operation>*

  </binding>
 </binding>

A processor no longer has to 'channel surf' between namespaces
when when populating the component model.

Possibly impacts the ability to process bindings generically at
the XML level - a processor has to be aware of the binding namespace
in order to obtain properties common across all bindings.
Not sure there are any good use-cases for this.

There could be some loss of common binding processor code re-use?

I'd suggest if this were to adopt this route, we publish a separate
(chameleon?) schema which a template author could extend or use as
a template (copy and corrupt).


FreeForm Binding Syntax
-----------------------

Having taken the step to move each binding into its own namespace,
here is a further quite radical step we could take:

  Given a processor has to understand a binding namespace to be able
  to use it and each binding implements the complete interface,
  why make the syntax for each binding uniform at all?

The publisher of a binding would be at liberty to decide on any
syntax that best describes his protocol rather than being constrained
by a WSDL binding template. All should be well so long as the author
of a binding specification clearly described how to move the infoset
to and from the WSDL binding component model.

 <binding name="xs:NCName" interface="xs:QName"? >
    <documentation />?

    <soapBinding  xmlns="http://www.w3.org/2003/11/wsdl/soap12">
        ... cool SOAP specific syntax
   </soapBinding>

    <rayGunBinding  xmlns="http://www.w3.org/2003/11/wsdl/soap12">
        ... cool lawn cutting specific syntax ...
   </rayGunBinding>
 </binding>

This has obvious advantages for bindings where the notion of an operation
or fault is either very obvious or meaningless. It may simplify our spec
and resolve a lot of our binding issues by making them more solvable on
a per-biding basis.

Consider the HTTP binding which comes with four default methods. Why
force this binding to describe these methods, or talk in terms of
operations at all, just to satisfy the 'WSDL binding template'?

I hope that captures the thrust of the discussion, promotes further
debate and made the best use of my jet-lag :-)

Paul

--
Paul Sumner Downey
Web Services Integration
BT Exact

[1]
http://dev.w3.org/cvsweb/~checkout~/2002/ws/desc/wsdl20/wsdl20-bindings.html

#soap-binding

Received on Thursday, 20 May 2004 07:53:50 UTC