You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When an event is created and there's a subscriber attached to the topic, only the current instance runs the function.
This is ideal, when we want to react to the event only once - for example: "Entity status change sends a notification".
When Ayon is scaled (there are multiple instances of the server itself), we also need a way how to trigger the function on all instances.
For example "Settings of the addon changed, so all addon instances has to reload the cache".
Proposal:
Add another parameter all_nodes: bool (defaulting to False) to EventStream.subscribe method.
When set to True, the function will be triggered on all instances of the server.
Implementation:
Hooks need to be split to groups (all / current node). Implementation for current node remains the same,
while all_nodes require implementation in ayon_server.api.messaging
The text was updated successfully, but these errors were encountered:
When an event is created and there's a subscriber attached to the topic, only the current instance runs the function.
This is ideal, when we want to react to the event only once - for example: "Entity status change sends a notification".
When Ayon is scaled (there are multiple instances of the server itself), we also need a way how to trigger the function on all instances.
For example "Settings of the addon changed, so all addon instances has to reload the cache".
Proposal:
Add another parameter
all_nodes: bool
(defaulting toFalse
) toEventStream.subscribe
method.When set to
True
, the function will be triggered on all instances of the server.Implementation:
Hooks need to be split to groups (all / current node). Implementation for current node remains the same,
while all_nodes require implementation in
ayon_server.api.messaging
The text was updated successfully, but these errors were encountered: