liveBook · Manning

Global state

As explained in Event Processing in Action

Global state is stateful data shared across event-processing agents or obtained from outside the event-processing application.

Global state is data available to event processing agents and contexts beyond the contents of a single event. It may be shared across agents or obtained from outside the event processing application. Unlike an agent’s local state, it is not confined to one agent’s processing. section 6.4 section 2.3.3

Global state can take several forms:

  • Event store: historical events retained for later processing. section 6.4
  • Reference data: data used to enrich or cleanse events, but not maintained by the event processing system. section 6.4
  • External state: the state of an outside entity, such as a business process or an airport alert level. An event consumer may change it in response to an event. section 6.4
  • Event processing state: data accessible across agents and updatable by the application, held in shared memory or persisted to disk. section 6.4

In an event processing network, a global state element represents stateful data used by agents. Dashed edges connect it to those agents, distinguishing data transfer from the event transfers shown with solid edges. A definition element identifies the state entity and its type. section 6.1.1 section 6.4

Fast Flower Delivery

The delivery application uses neighborhood data and store information as reference data. It also maintains driver status as event processing state, including driver ID, ranking, and current neighborhood. section 6.4

Table 6.8. Global state elements in the Fast Flower Delivery application

Element identifier

Element type

Metadata

Input event type

Neighborhoods Reference data Geospatial database schema ��
Driver status Event processing state Driver ID, Driver ranking, Current neighborhood Ranking Increase Ranking Decrease Driver Location
Store reference Reference data Store name, Minimum ranking, Store location, Store region, Automatic assignment flag ��

Compare the application’s global state elements, their types, metadata, and associated input events. section 6.4

How Event Processing in Action covers it

How deep it goes
Defines four state types and describes their representation with identifiers, types, nodes, and data-transfer edges.
Examples
Uses delivery neighborhoods, store information, and driver status to illustrate reference data and event processing state.
What you can do after
Evaluate and represent global state needs in an event processing network.
How it connects
Connects global state to event processing agents, contexts, event stores, reference data, and event processing networks.

Also explained in

Compare how 2 books explain global state →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Event Processing in Action. The section links point to the parts of the book it draws on.