finitomata
finitomata copied to clipboard
demo phx 1.7 live view + finitomata + ecto?
hello
may I be so bold to ask if there is an example of phx 1.7 live view + finitomata + ecto?
if not, why? or why not?
if I made a demo, any pointers to using the example ecto_integration and the generator-driven scaffolds in phx 1.7?
is finitomata designed to be used only on custom phoenix apps or can it work with phx 1.7 mainline apps?
I see https://github.com/am-kantox/eblox but its a static site generator and was hoping for a more basic pattern I could draw from
I would like some guidance on the persistence of finitomata fsm used with say the latest live view generated code
its all a bit new, and there are zero examples afaik
apologies if this is the incorrect forum
thank you
Hi @niccolox,
the library itself is not tied to any phx/ecto version. It might be used as a business process handler in contexts, but it also might be used in any other way. It does not depend on phx/ecto, neither phx/ecto is connected to it in any way.
I am lazily working on the more concise example, involving ecto, but in general, I want it to stay as disconnected from web/persistence as possible.
I will leave this issue open to link it when more examples are to come.
fair enough @am-kantox
I saw the defimpl Finitomata.Persistency.Persistable, for: EctoIntegration.Data.Post do
and was wondering if there was an integration pattern I was missing
https://github.com/am-kantox/finitomata/blob/f9284a623f40c333d4215a5379f514a534c3a959/examples/ecto_integration/lib/ecto_integration/data/post/persistable.ex#L1
I can do some discovery around finitomata +phx 1.7 live view and ecto
thank you for interesting work
Well, technically one might use Finitomata.Persistency.Persistable
implementation in combination with Finitomata.Persistency
to simplify the loading/storing FSM with a state into/from any storage, including, but not limited to DB.
This is not a well-thought concept yet (although it should work,) as in general, I am not concerned about how distributed FSM should have been handled. There would be many pitfalls and the architecture is still under heavy rethinking.