ObanPowertools.Telemetry (oban_powertools v0.5.0)

Copy Markdown View Source

Public telemetry contract for Oban Powertools.

Phase 8 freezes five event families under the [:oban_powertools, family, event_suffix] prefix:

  • :operator_action
  • :limiter
  • :cron
  • :workflow
  • :lifeline

The public measurement key is :count.

Allowed low-cardinality metadata keys per family:

  • :operator_action -> [:action, :source]
  • :limiter -> [:action, :blocker_code, :resource, :scope]
  • :cron -> [:action, :source, :overlap_policy, :catch_up_policy]
  • :workflow ->
    • :step_completed -> [:outcome, :terminal_cause, :semantics_version]
    • :step_unblocked -> [:scope, :state, :semantics_version]
    • :cascade_cancelled -> [:scope, :outcome, :terminal_cause, :semantics_version]
    • :workflow_terminal -> [:state, :outcome, :terminal_cause, :semantics_version]
  • :lifeline -> [:action, :incident_class, :target_type, :outcome, :archived_count, :pruned_count]

IDs, job args, preview tokens, and free-form reasons are intentionally excluded from this public API.

Summary

Functions

contract()

Returns the public telemetry contract for event families, measurements, and metadata keys.

execute_cron_event(event_suffix, measurements \\ %{}, metadata \\ %{})

execute_lifeline_event(event_suffix, measurements \\ %{}, metadata \\ %{})

execute_limiter_event(event_suffix, measurements \\ %{}, metadata \\ %{})

execute_operator_action(event_suffix, measurements \\ %{}, metadata \\ %{})

Executes a telemetry event for an operator action.

execute_workflow_event(event_suffix, measurements \\ %{}, metadata \\ %{})