recipe v0.4.3 Recipe.Telemetry behaviour View Source

The Recipe.Telemetry behaviour can be used to define a module capable of handling events emitted by a recipe run.

Each callback is invoked at different step of a recipe run, receiving data about the current step and its execution time.

Please refer to the docs for Recipe.run/3 to see how to enable debug and telemetry information.

Link to this section Summary

Callbacks

Invoked after failing to execute a step

Invoked at the end of a recipe execution, irrespectively of the success or failure of the last executed step

Invoked at the start of a recipe execution

Invoked after successfully executing a step

Link to this section Types

Link to this type elapsed_microseconds() View Source
elapsed_microseconds() :: integer

Link to this section Callbacks

Link to this callback on_error(arg0, term, arg2, elapsed_microseconds) View Source
on_error(Recipe.step, term, Recipe.t, elapsed_microseconds) :: :ok

Invoked after failing to execute a step.

Link to this callback on_finish(arg0) View Source
on_finish(Recipe.t) :: :ok

Invoked at the end of a recipe execution, irrespectively of the success or failure of the last executed step.

Link to this callback on_start(arg0) View Source
on_start(Recipe.t) :: :ok

Invoked at the start of a recipe execution.

Link to this callback on_success(arg0, arg1, elapsed_microseconds) View Source

Invoked after successfully executing a step.