PgFlow.CronSummary (PgFlow v0.3.4)

Copy Markdown View Source

Typed operational statistics and schedule data for a PgFlow cron definition.

last_run_at is the completion time of the definition's most recent PgFlow run. next_run_at is the next scheduled instant in UTC.

Summary

Functions

Builds a cron summary from a complete query projection.

Types

t()

@type t() :: %PgFlow.CronSummary{
  avg_duration_ms: Decimal.t(),
  completed_runs_24h: non_neg_integer(),
  cron_expression: String.t(),
  failed_runs_24h: non_neg_integer(),
  flow_slug: String.t(),
  flow_type: String.t(),
  is_active: boolean(),
  last_run_at: DateTime.t() | nil,
  last_run_status: String.t() | nil,
  next_run_at: DateTime.t() | nil,
  opt_base_delay: non_neg_integer(),
  opt_max_attempts: non_neg_integer(),
  opt_timeout: pos_integer(),
  p95_duration_ms: float(),
  success_rate_24h: Decimal.t(),
  total_runs_24h: non_neg_integer()
}

Functions

new(attributes)

@spec new(map()) :: t()

Builds a cron summary from a complete query projection.