Issue 17213: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? (fuml-rtf) Source: Commissariat a l Energie Atomique-CEA (Dr. Arnaud Cuccuru, arnaud.cuccuru(at)cea.fr) Nature: Uncategorized Issue Severity: Summary: It seems that in ActionActivation.sendOffers(), a loop for sending a control token on outgoing edges is missing. The code should probably be completed with something like: // *** Send offers on all outgoing edges concurrently. *** ActivityEdgeInstanceList outgoingEdges = this.outgoingEdges; for (Iterator i = outgoingEdges.iterator(); i.hasNext();) { ActivityEdgeInstance outgoingEdge = (ActivityEdgeInstance)i.next(); TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); outgoingEdge.sendOffer(tokens); } Resolution: agreed Revised Text: In Subclause 8.6.2.2.1 ActionActivation, add the following to the end of operation [15] sendOffers(): // Send offers on all outgoing control flows. if (this.outgoingEdges.size() > 0) { TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); this.addTokens(tokens); this.outgoingEdges.getValue(0).sendOffer(tokens); } Actions taken: March 8, 2012: received issue January 7, 2013: closed issue Discussion: End of Annotations:===== m: Ed Seidewitz To: CUCCURU Arnaud Subject: RE: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? Arnaud . This also seems to be a document problem. The execution model itself includes the following additional code for ActionActivation::sendOffers that does not appear in the document: // Send offers on all outgoing control flows. if (this.outgoingEdges.size() > 0) { TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); this.addTokens(tokens); this.outgoingEdges.getValue(0).sendOffer(tokens); } Note that a loop is not necessary. The outgoing ActivityEdgeInstances from an ActionActivation get shifted to an anonymous ForkNodeActivation (to implement the .fork-equivalent. semantics of multiple control flows coming out of an), so there is at most one outgoing edge from an ActionActivation (see ActionActivation::addOutgoingEdge). But an issue is still appropriate, so we can keep the spec document .honest.. Thanks for another catch. I am glad someone else is finally giving the details of the specification a good looking over! -- Ed -------------------------------------------------------------------------------- From: CUCCURU Arnaud [mailto:arnaud.cuccuru@cea.fr] Sent: Thursday, March 08, 2012 4:19 AM To: Ed Seidewitz; fuml-rtf@omg.org Subject: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? Hello Ed, all, It seems that in ActionActivation.sendOffers(), a loop for sending a control token on outgoing edges is missing. The code should probably be completed with something like: // *** Send offers on all outgoing edges concurrently. *** ActivityEdgeInstanceList outgoingEdges = this.outgoingEdges; for (Iterator i = outgoingEdges.iterator(); i.hasNext();) { ActivityEdgeInstance outgoingEdge = (ActivityEdgeInstance)i.next(); TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); outgoingEdge.sendOffer(tokens); } If you agree with that, I can and prepare a resolution and ask Juergen for logging an issue. Cheers, Arnaud CUCCURU CEA LIST, Ingéeur chercheur Laboratoire d.Ingéerie dirigépar les modès pour les Systès Embarqué(LISE) Tel : + 33 1 69 08 49 61 Fax : + 33 1 69 08 20 82 From: Ed Seidewitz To: "fuml-rtf@omg.org" Date: Thu, 8 Mar 2012 13:18:28 -0500 Subject: RE: issue 17213 -- fUML RTF issue Thread-Topic: issue 17213 -- fUML RTF issue Thread-Index: Acz9VCPerOOJnLANTYGRMJs9nO040wAA4LdQ Accept-Language: en-US X-MS-Has-Attach: yes X-MS-TNEF-Correlator: acceptlanguage: en-US X-Mailprotector-Decision: deliver X-Mailprotector-Connection: TLSv1|[10.1.50.225]|10.1.50.225|outbound.mailprotector.net|-0.986265|0.924353|0|white|ugly|7809|54|0|0 X-Mailprotector-Results: null_ptr clean X-Mailprotector-Score: 40 X-Mailprotector-IP-Analysis: 0, 10.1.50.225, Ugly c=0.924393 p=-0.98627 Source White X-Mailprotector-Scan-Diagnostics: 0-0-0-32767-c X-Mailprotector-ID: 8d6537e4-449d-4930-9258-f9d58b0580f0 Since this issue is also just a document correction, I have added it to the draft ballot, too. The updated draft is attached. -- Ed -------------------------------------------------------------------------------- From: Juergen Boldt [mailto:juergen@omg.org] Sent: Thursday, March 08, 2012 12:46 PM To: issues@omg.org; fuml-rtf@omg.org Subject: issue 17213 -- fUML RTF issue From: Ed Seidewitz To: CUCCURU Arnaud CC: "fuml-rtf@omg.org" Date: Thu, 8 Mar 2012 12:38:13 -0500 Subject: RE: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? Thread-Topic: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? Thread-Index: Acz9CbTUSXdGJL02QVae2keO/1wJJwAR2VaA Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US X-Mailprotector-Decision: deliver X-Mailprotector-Connection: TLSv1|[10.1.50.226]|10.1.50.226|outbound.mailprotector.net|-0.996991|0.870265|0|white|ugly|4645|7|0|0 X-Mailprotector-Results: null_ptr subject_50_chars clean X-Mailprotector-Score: 60 X-Mailprotector-IP-Analysis: 0, 10.1.50.226, Ugly c=0.870265 p=-0.996991 Source White X-Mailprotector-Scan-Diagnostics: 0-0-0-21951-c X-Mailprotector-ID: 5225da11-09c7-46c2-8bca-4009758b3a16 Arnaud This also seems to be a document problem. The execution model itself includes the following additional code for ActionActivation::sendOffers that does not appear in the document: // Send offers on all outgoing control flows. if (this.outgoingEdges.size() > 0) { TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); this.addTokens(tokens); this.outgoingEdges.getValue(0).sendOffer(tokens); } Note that a loop is not necessary. The outgoing ActivityEdgeInstances from an ActionActivation get shifted to an anonymous ForkNodeActivation (to implement the fork-equivalent semantics of multiple control flows coming out of an), so there is at most one outgoing edge from an ActionActivation (see ActionActivation::addOutgoingEdge). But an issue is still appropriate, so we can keep the spec document honest. Thanks for another catch. I am glad someone else is finally giving the details of the specification a good looking over! -- Ed -------------------------------------------------------------------------------- From: CUCCURU Arnaud [ mailto:arnaud.cuccuru@cea.fr] Sent: Thursday, March 08, 2012 4:19 AM To: Ed Seidewitz; fuml-rtf@omg.org Subject: ActionActivation.sendOffers(): Missing sending of offers on outgoing control flows? Hello Ed, all, It seems that in ActionActivation.sendOffers(), a loop for sending a control token on outgoing edges is missing. The code should probably be completed with something like: // *** Send offers on all outgoing edges concurrently. *** ActivityEdgeInstanceList outgoingEdges = this.outgoingEdges; for (Iterator i = outgoingEdges.iterator(); i.hasNext();) { ActivityEdgeInstance outgoingEdge = (ActivityEdgeInstance)i.next(); TokenList tokens = new TokenList(); tokens.addValue(new ControlToken()); outgoingEdge.sendOffer(tokens); } If you agree with that, I can and prepare a resolution and ask Juergen for logging an issue. Cheers, Arnaud CUCCURU CEA LIST, Ing.eur chercheur Laboratoire dIng.erie dirig.par les mod.s pour les Syst.s Embarqu.(LISE) Tel : + 33 1 69 08 49 61 Fax : + 33 1 69 08 20 82 Juergen Boldt Director, Member Services 140 Kendrick Street, Building A Suite 300 Needham, MA 02494 USA Tel: 781 444 0404 x 132 fax: 781 444 0320 www.omg.org