  We define two complementary approaches to monitor decentralized systems. The
first relies on those with a centralized specification, i.e, when the
specification is written for the behavior of the entire system. To do so, our
approach introduces a data-structure that i) keeps track of the execution of an
automaton, ii) has predictable parameters and size, and iii) guarantees strong
eventual consistency. The second approach defines decentralized specifications
wherein multiple specifications are provided for separate parts of the system.
We study two properties of decentralized specifications pertaining to
monitorability and compatibility between specification and architecture. We
also present a general algorithm for monitoring decentralized specifications.
We map three existing algorithms to our approaches and provide a framework for
analyzing their behavior. Furthermore, we introduce THEMIS, a framework for
designing such decentralized algorithms and simulating their behavior. We show
the usage of THEMIS to compare multiple algorithms and verify the trends
predicted by the analysis by studying two scenarios: a synthetic benchmark and
a real example.
