Programmatically Build a State Machine
Asked Answered
K

1

7

With the new Spring Statemachine project, can I create a state machine programmatically without using adapter classes available for JavaConfig and Spring @Configuration classes?

Ker answered 18/4, 2015 at 12:58 Comment(0)
A
3

We're currently missing a generic builder pattern for building machine as a pojo. It's surely possible to use needed classes manually but looking a unit tests this approach is too verbose.

Based on discussions after we got 1.0.0.M1 out, a better low level builder api is needed. Although we can create a factory based on JavaConfig but still this may not be enough for some use cases.

I've created a new issue https://github.com/spring-projects/spring-statemachine/issues/45 to track this. So either we add a generic builder or if that model turns out to be too convoluted, then possibly a set of recipe modules could be used to create easy configuration for specific use cases.

Acree answered 18/4, 2015 at 14:27 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.