W3C home > Mailing lists > Public > public-ws-chor@w3.org > October 2004

Re: Proposal: To remove the initiate flag on the Interation

From: Gary Brown <gary@enigmatec.net>
Date: Mon, 25 Oct 2004 19:16:51 +0100
Message-ID: <003901c4babe$d2ce6230$0200a8c0@LATTITUDEGary>
To: "Nickolas Kavantzas" <nickolas.kavantzas@oracle.com>, <public-ws-chor@w3.org>
I accept this response - and therefore will withdraw the proposal.

However, I think we need to consider the implication of interactions occuring between parties, prior to the choreography being seen to have been initiated. If we were being very strict, we may decide that all communications from a particular participant must be associated with a choreography, and therefore that the first communication must match an initiating interaction. Perhaps a discussion point on tomorrow's conf call.

Regards
Gary


  ----- Original Message ----- 
  From: Nickolas Kavantzas 
  To: Gary Brown ; public-ws-chor@w3.org 
  Sent: Monday, October 25, 2004 6:12 PM
  Subject: Re: Proposal: To remove the initiate flag on the Interation


  Gary,

  I agree with you that there are inconsistencies within the Choreo Life-line section 
  but I do believe that the *initiate* attribute is desirable:

  The initiate attribute in the interaction marks an interaction as 
  the operation that establishes the collaboration between parties. 

  In essence, a Choreography designer must first decide whether a Choreography 
  can start the collaboration when it is performed, or it expects the 
  collaboration to be already started when it is performed (otherwise there is an error). 
  Without this declarative mechanism this would be impossible to specify and check, 
  especially when composing Choreographies.

  Below is an example that demonstrates this:

  Choreography C1 and Choreography C2 are designed first.
  Choreography C2 does not have an Initating Interaction but
  Choreography C1 does.

  <choreography name="C1">
         <interaction  initiate="true">
           .......
         </interaction>
  <choreography>

  <choreography name="C2">
         <interaction  initiate="false">
           .......
         </interaction>
  <choreography>


  Later Choreography C is designed by composing Choreography C1 and Choreography C2.
  So Choreography C must perform Choreography C1 and Choreography
  C2. Since Choreography C2 does not have the Initating Interaction 
  whereas Choreography C1 does, performing C2 before C1 is incorrect
  and the static analysis should catch this error.

  The right way of composing C1 and C2 would then be:

  <choreography name="C" root="true">
        ....
      <seq>
         perform C1
         perform C2
      </seq>
  </choreography>


  In the case that both Choreographies C1 and C2 had an Initating 
  Interaction then the Choreography CC would be also correct (in addition
  to the Choreography C above):

  <choreography name="CC" root="true">
        ....
      <parallel>
         perform C1
         perform C2
      </parallel>
  </choreography>




  But as I said earlier there are inconsistencies within the Choreo Life-line 
  section (as you and Peter have pointed out), so below is my proposal for fixing 
  the Choreo Life-line section (including the proposal text that I sent to Peter 
  regarding the completion of a choreography):


  *Choreography Life-line*
  A Choreography life-line expresses the progression of a collaboration through 
  enabled activities and enclosed performed Choreographies.

  Initially, the collaboration MUST be established between parties, then work MAY be
  performed within it and finally it MAY complete. 

  A Choreography is initiated, establishing a collaboration when an  
  Interaction, explicitly marked as an Choreography initiator, is performed. 
  Before this point there is no observable association between any of the parties. 
  Two or more Interactions MAY be marked as Choreography initiators, indicating 
  alternatives for establishing a collaboration. In this case, the first performed 
  interaction will establish the collaboration and the other interactions will enlist
  with the already established collaboration. 
  An initiating interaction MAY be defined within a root Choreography or within either
  a Locally or a Globally defined enlosed Choreography. In either case the collaboration is 
  established when the initiating intaraction is performed.

  A Choreography completes successfully when there are no more matched Work
  Unit(s) performing work within it and there are no enabled Work Unit(s)
  within it. Alternatively, a Choreography completes successfully if its
  complete condition, as defined by the optional complete attribute within the
  choreography element, evaluates to "true". In this case, the actions,
  including enclosed Choreographies, within the explicitly completed
  Choreography are completed abnormally before the Choreography completes.



  --
  Nick



  ----- Original Message ----- 
    From: Gary Brown 
    To: public-ws-chor@w3.org 
    Sent: Thursday, October 21, 2004 1:52 AM
    Subject: Proposal: To remove the initiate flag on the Interation


    In the section 2.5.2.4, the interaction is defined as having an optional 'initiate' flag:

    "An Interaction activity can be marked as a Choreography initiator when the optional initiate attribute is set to "true". The default for this attribute is "false"."

    However, in section 2.4.7, it says:

    "The root Choreography is the only top-level Choreography that MAY be initiated."

    and then,

    "A root Choreography is initiated when the first Interaction, marked as the Choreography initiator, is performed. ....... An Interaction designated as a Choreography initiator MUST be the first action performed in a Choreography."

    Therefore, by implication, the first interaction of a root choreography is always going to initiate the choreography - so why do we need a flag to specify this fact? 

    Similarly, if two or more mutually exclusive or concurrent interactions may initiate the choreography, these could be inferred by having the appropriate <choice> or <parallel> constructs to group the set of initial interactions.
    <NK>You are right about this issue. This sentence needs to be removed</NK>


    Proposed Change:

    1) Remove para from 2.4.7:
    "A root Choreography is initiated when the first Interaction, marked as the Choreography initiator, is performed. Two or more Interactions MAY be marked as initiators, indicating alternative initiation actions. In this case, the first action will initiate the Choreography and the other actions will enlist with the already initiated Choreography. An Interaction designated as a Choreography initiator MUST be the first action performed in a Choreography. If a Choreography has two or more Work Units with Interactions marked as initiators, then these are mutually exclusive and the Choreography will be initiated when the first Interaction occurs and the remaining Work Units will be disabled. All the Interactions not marked as initiators indicate that they will enlist with an already initiated Choreography."

    2) Remove the 'initiate' flag from the Interaction syntax,  and the following para (from section 2.5.2.4):

    "An Interaction activity can be marked as a Choreography initiator when the optional initiate attribute is set to "true". The default for this attribute is "false"."

    3) Remove the 'initiate' flag from the example at the end of section 2.5.2.4.
Received on Monday, 25 October 2004 18:17:15 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 18 December 2010 01:01:06 GMT