The most basic pattern you can find in AIR scripts is sending particles to clients via a relay.
It looks like in the example below:
(seq (call relay ("op" "identity") ) (call client ("service" "function") [arg]) )
client is a variable with the value of the client PeerId, and
relay is equal to the PeerId of the node which the client is connected to. The following picture might explain the situation better.
So, for the particle to reach the client behind the relay, the script must explicitly specify this network topology as follows:
- Go to the relay, do nothing (
- Go to the client, execute the required function.
Updated about a month ago