- From: Stefan Radomski <radomski@tk.informatik.tu-darmstadt.de>
- Date: Mon, 20 Jan 2014 10:15:29 +0000
- To: "www-voice@w3.org (www-voice@w3.org)" <www-voice@w3.org>
Hey there,
as we continue to use SCXML for various applications, there is one deficiency that always bugged us. Consider that you have a state that will invoke something and you’d like to send some event to it right-away. You cannot use <send target=“#_invokeid”> in an onentry element as the invoker will not yet exist, it is only invoked when a stable configuration is reached (see procedure mainEventLoop in the draft). Thus forcing you to use a delay attribute.
<state id=“foo”>
<invoke type=“something” id=“something” />
<onentry>
<!— this will fail as the invoker does not yet exist -->
<send target=“#_something” event=“do.something” />
<!— this will work as we had an empty internal queue -->
<send target=“#_something” event=“do.something” delay=“1ms" />
</onentry>
</state>
Is anyone else bugged by this behavior and resorted to the delayed send idiom, is there something more straight-forward or did we misinterpret the SCXML draft at some point?
If this is indeed correct behavior, maybe we could specify that an invoker *must* raise some internal event after being successfully invoked?
Best regards
Stefan
Received on Monday, 20 January 2014 10:15:54 UTC