W3C home > Mailing lists > Public > public-ws-chor@w3.org > April 2005

PROPOSAL related to: Example showing problem with current isolation semantics in CDL

From: Gary Brown <gary@pi4tech.com>
Date: Wed, 20 Apr 2005 09:13:02 +0100
Message-ID: <002301c54580$c7c27eb0$0200a8c0@GPB1>
To: <public-ws-chor@w3.org>
We should clearly state in the spec that nested isolation choreographies are not permitted.

Proposed Text:

Section 2.4.5 contains the following bullet point:

" When isolation is set to "true", changes to the Variable information MUST be visible for read or for write to its sibling Choreographies only after this Choreography has completed "

This should be extended to include the text:

"An isolated choreography cannot directly or indirectly perform another isolated choreography."


  ----- Original Message ----- 
  From: Gary Brown 
  To: public-ws-chor@w3.org 
  Sent: Tuesday, April 19, 2005 12:56 PM
  Subject: Example showing problem with current isolation semantics in CDL


  After the recent discussion on isolation being inherited from the enclosing choreography, I wanted to outline the following example to show how simply changing the isolation attribute of an enclosing choreography can significantly change the behavior of the choreography.

  <choreo A>
      <variable name="var1" /> 
      <variable name="var2" />
      <choreo B isolation=true >
          <assign value "x" to "var1" /> 
          <assign value "x" to "var2" />
      <choreo C isolation=true > 
          <assign value "y" to "var1" /> 
          <assign value "y" to "var2" />

          <perform choreo B>
               <bind var1/>
               <bind var2/>
          <perform choreo C>
               <bind var1/>
               <bind var2/>

  If choreo A is not isolated, then choreo B and C are isolated in their own right - and therefore because they are both accessing common variables, I assume that one or the other of the performs will wait until the other has completed - so in fact they will be performed in sequence. [If this assumption is not true, then I need to have an explanation of the behavior when two sub-choreos have the same isolated variable - at what point do they wait?]

  Therefore the result would be that both variables would have the same value - either 'x' or 'y' depending on the order in which the sub-choreos were actually performed.

  However, if we now make choreo A isolated, the isolated attribute on B and C is now ignored, as the isolation is inherited from the parent choreography (as described at the last f2f).

  This now means that because the variables 'var1' and 'var2' are within the same isolation scope, when the two sub-choreos are performed, there is no waiting/blocking. This means that the result of the overall choreography is non-deterministic, the variables could have any combination of 'x' or 'y'.

  The problem is that a sub-choreography may be defined on the basis of having isolation semantics - and this is effectively overridden when performed from an already isolated choreography. Whereas if nested isolation was supported, the semantics of the sub-choreographies would be preserved, regardless of the isolation status of the enclosing choreography.

  This example is showing a simple example, but in a real example the isolation of a top level choreography could have unforeseen consequences on a sub-choreography that is many levels of nesting removed from the isolated choreography. A case of a small change having a significant impact on bahavior.

Received on Wednesday, 20 April 2005 08:13:10 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:30:31 UTC