|Home > Iris APIs > Notification and discovery of state changes > Event source IRIS_STATE_CHANGED|
An instance generates this event whenever its state is modified by another instance. Clients should re-read all relevant state from instances because it might have changed.
IRIS_STATE_CHANGED events are generated
automatically when any of the following state is changed by an Iris function:
This event is not guaranteed to be generated after changes to the following:
IRIS_INSTANCE_REGISTRY_CHANGEDfor this change.
IRIS_SIMULATION_TIME_EVENTfor this change.
IRIS_STATE_CHANGED events are hints
that state might have changed. They might be sent even if no change happened.
IRIS_STATE_CHANGED has no fields. It
does not provide information about what changed or in which instances because it is
generally impossible to determine this information accurately. For example, a memory
write might change arbitrary registers in the same instance or in other instances,
or a resource write might change anything in the same instance or in other
instances, including memory, tables, and the sync level.
IRIS_STATE_CHANGED event is
generated with a slight delay after the last state change was observed by the global
instance. The maximum delay for a single state change is about 500ms and the maximum
rate is about 1 event every 500ms. The purpose of the delay is to suppress multiple
events from occurring because of many state changes in a short period of time.
Clients are usually only interested in the final state change in a set of changes,
so they can update their views once, after all changes have finished.