reconciler

package
v1.0.0-beta.231 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 14, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Reconciler

type Reconciler struct {
	// contains filtered or unexported fields
}

Reconciler is a component that periodically reconciles the subscription state with the billing state this is essential, as the invoice creation is purley event driven. In case a processing error happens, we might fail to create an invoice, and stop processing the subscription.

func NewReconciler

func NewReconciler(config ReconcilerConfig) (*Reconciler, error)

func (*Reconciler) All

func (*Reconciler) ListSubscriptions

func (*Reconciler) ReconcileSubscription

func (r *Reconciler) ReconcileSubscription(ctx context.Context, subsID models.NamespacedID) error

type ReconcilerAllInput

type ReconcilerAllInput struct {
	ReconcilerListSubscriptionsInput
	Force bool
}

type ReconcilerConfig

type ReconcilerConfig struct {
	SubscriptionSync    subscriptionsync.Service
	SubscriptionService subscription.Service
	CustomerService     customer.Service
	Logger              *slog.Logger
}

func (ReconcilerConfig) Validate

func (c ReconcilerConfig) Validate() error

type ReconcilerListSubscriptionsInput

type ReconcilerListSubscriptionsInput struct {
	Namespaces []string
	Customers  []string
	Lookback   time.Duration
}

func (ReconcilerListSubscriptionsInput) Validate

type SubscriptionWithSyncState

type SubscriptionWithSyncState struct {
	subscription.Subscription
	*subscriptionsync.SyncState
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL