What is StatefulJ?

StatefulJ is a lightweight, open source Java Event Driven Finite State Machine(FSM) and a complete Spring Data based framework which lets you easily define and integrate State Machines into your Applications.

What is a Finite State Machine?

I won’t go into detail here as there is a lot already written about them. But the important thing is that an FSM allows you to model all your Domain events and State transitions into a coherent and testable package instead of writing a scattershot of boolean flags and if-then statements.

Why should I use StatefulJ?

Applications have to manage and orchestrate synchronous and asynchronous requests and events from many sources: REST and SOAP APIs, Web Page requests, Message Queues, Internal Application Events, etc… Handling concurrency and reliably updating Application state becomes a major challenge without the proper framework.

By making it easy to integrate State Machines into your Application, StatefulJ provides you the ability to meet these challenges by creating State Models instead of writing ad-hoc code.

What does StatefulJ provide?

StatefulJ provides the following “packages”:

How do I get started?

If you just want the StatefulJ FSM package, then follow these instructions

If you want to integrate the StatefulJ Framework, then follow these instructions