Sibling machine communication #4950
Unanswered
benjaminpreiss
asked this question in
Q&A
Replies: 1 comment
-
Using a different approach (namely, a system of machines) I am able to receive events on one of the children by sending the event to them directly: sendTo(({ system }) => system.get("data"), {
type: "AUTH_LOADED",
}) I would prefer though to be able to send an event to every machine in a system, without explicitly naming them. Is that possible? Edit: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I want to enable communication between sibling machines in a system of machines, where the machines run in parallel.
As the docs are relatively sparse on the topic, I am not sure how to model state systems and how child machines can communicate with each other.
Nevertheless, I have now created a sandbox where the child machines are children of a
parallel
type root machine.The authentication machine should then send a signal to the data loader machine once the authentication is loaded, so that the data loader machine can start loading data
I am trying to achieve this functionality by calling
raise()
on entry of theauthenticated
state. But it seems that the data loader machine does not receive this signal.Here is the repro: https://codesandbox.io/p/devbox/zen-https-x8trsl?file=%2Fsrc%2FApp.svelte%3A4%2C63
I am super glad for a hint or correct code example... And additionally maybe an explanation on how systems can help in the matter!
Edit
Most specifically I want to send and event to every sibling machine at once
Beta Was this translation helpful? Give feedback.
All reactions