public interface ISystemState
System states are declared as components of type com.zfabrik.systemState
.
The most important use-case of this is the heterogeneous designation of worker processes to different purposes using the system state mechanism. In essence, the runtime should only download resources of component and execute components as far as required for the implemented scenario. The system state mechanism allows to define scenario requirements via a graph of system state and component dependencies. See also the worker process javadoc.
System states can be attained. Attaining a system state translates to preparing (see IDependencyComponent
) all
components that declare a participation in the state using the configuration property STATES_PARTICIPATION
or by declaring
STATES_DEPENDENCY
on the state.
System states implement IDependencyComponent
. When preparing, all dependencies will be prepared as well. This happens during any verification and
synchronization so that system state's will be re-enforced at that point in time.
For example, the system state com.zfabrik.boot.main/process_up
is declared like this:
# # a system state # com.zfabrik.component.type=com.zfabrik.systemState # # it's a generalization that applies to worker processes # as well as home processes. For example, the distributed # component provisioning participates in this state to advertise # itself at the package management # com.zfabrik.systemStates.participation=\ * com.zfabrik.boot.main/home_up,\ * com.zfabrik.boot.main/worker_up # #
Modifier and Type | Field | Description |
---|---|---|
static java.lang.String |
STATES_DEPENDENCY |
State components declare dependency on other components by specifying a comma-separated list of component names.
|
static java.lang.String |
STATES_PARTICIPATION |
Components declare participation in a state components life cycle by specifying a comma-separated list of component names.
|
static java.lang.String |
TYPE |
Type of a system state component.
|
static final java.lang.String TYPE
static final java.lang.String STATES_DEPENDENCY
IDependencyComponent
and will be invoked when the
state component gets prepared, which is in particular
IComponentDescriptor.DEPENDENCIES
static final java.lang.String STATES_PARTICIPATION
STATES_DEPENDENCY
declaration
but declared on the other end of the vector.