AuroraMeter. Schema. PlanTransition
(Aurora Meter v1.0.0)
View Source
The audit row for one scheduled, applied or cancelled plan change.
Created by build unit 07a and written by nobody yet. The table and the schema ship together with core schema version 10 so that 07b adds behaviour rather than DDL, and so that a host upgrading to 1.0.0-rc.1 runs one core migration for the whole of phase 07 rather than two.
ref is the caller's idempotency reference, unique per tenant. confirm says
whether the transition may be applied locally ("local") or must wait for the
billing provider to confirm the price change ("provider"); it is mirrored
onto aurora_meter_subscriptions.transition_confirm so Pro can find due
provider work with one indexed keyset query over the subscriptions table
instead of a jsonb predicate over this one.
Summary
Functions
Builds a changeset for a plan transition.
The confirmation modes a transition row may be in.
The states a transition row may be in.
Types
@type t() :: %AuroraMeter.Schema.PlanTransition{ __meta__: term(), applied_at: term(), confirm: term(), detail: term(), effective_at: term(), from_plan_id: term(), from_version: term(), id: term(), inserted_at: term(), provider_ref: term(), ref: term(), state: term(), tenant_key: term(), to_plan_id: term(), to_version: term(), updated_at: term() }
Functions
@spec changeset(t(), map()) :: Ecto.Changeset.t()
Builds a changeset for a plan transition.
@spec confirmations() :: [String.t()]
The confirmation modes a transition row may be in.
@spec states() :: [String.t()]
The states a transition row may be in.