skuld_durable

EffectLogger & SerializableCoroutine > | Umbrella →

Durable execution for Skuld: pause-serialize-resume workflows and effect logging.

What's included

Installation

def deps do
[
{:skuld_durable, "~> 0.32"}
]
end

Quick start

alias Skuld.SerializableCoroutine
sc = SerializableCoroutine.new(MyWizard.run(), fn comp ->
comp |> State.with_handler(%{}) |> Yield.with_handler() |> Throw.with_handler()
end)
# Fresh start — suspends at first yield
suspended = SerializableCoroutine.run(sc)
# Serialize and persist
json = SerializableCoroutine.serialize(SerializableCoroutine.get_log(suspended))
# Later: cold resume from serialised state
SerializableCoroutine.run(json, sc, resume_value)

See the architecture guide for how this fits into the Skuld ecosystem.


EffectLogger & SerializableCoroutine > | Umbrella →