Confuse on the multi-instance variables

A local variable is only visible within its scope and its child scopes (e.g. a subprocess).

A local variable is usually created by defining it via input mapping (e.g. on a subprocess).

A local variable is often used to prevent that a variable is propagated to the workflow instance (root) scope and visible to other activities.

The input mappings can be used to create new local variables in the scope of an instance. These variables are only visible within the instance. It is a way to restrict the visibility of variables. By default, new variables (e.g. provided by a job worker) are created in the scope of the workflow instance and are visible to all instances of the multi-instance activity as well as outside of it. In case of a parallel multi-instance activity, this can lead to variables that are modified by multiple instances and result in race conditions. If a variable is defined as local variable, then it is not propagated to a parent or the workflow instance scope and can’t be modified outside of the instance.

Does this answer your question?