Documentation ¶
Index ¶
- func New(ctx context.Context, dsn string, adm *admin.Service) (jobs.Client, error)
- type Client
- func (c *Client) CancelJob(ctx context.Context, jobID int64) error
- func (c *Client) Close(ctx context.Context) error
- func (c *Client) CustomerAddressUpdated(ctx context.Context, paymentCustomerID string, eventTime time.Time) (*jobs.InsertResult, error)
- func (c *Client) InitOrgBilling(ctx context.Context, orgID string) (*jobs.InsertResult, error)
- func (c *Client) PaymentFailed(ctx context.Context, ...) (*jobs.InsertResult, error)
- func (c *Client) PaymentMethodAdded(ctx context.Context, paymentMethodID, paymentCustomerID, paymentType string, ...) (*jobs.InsertResult, error)
- func (c *Client) PaymentMethodRemoved(ctx context.Context, paymentMethodID, paymentCustomerID string, ...) (*jobs.InsertResult, error)
- func (c *Client) PaymentSuccess(ctx context.Context, billingCustomerID, invoiceID string) (*jobs.InsertResult, error)
- func (c *Client) PurgeOrg(ctx context.Context, orgID string) (*jobs.InsertResult, error)
- func (c *Client) RepairOrgBilling(ctx context.Context, orgID string) (*jobs.InsertResult, error)
- func (c *Client) ResetAllDeployments(ctx context.Context) (*jobs.InsertResult, error)
- func (c *Client) StartOrgTrial(ctx context.Context, orgID string) (*jobs.InsertResult, error)
- func (c *Client) Work(ctx context.Context) error
- type CustomerAddressUpdatedArgs
- type CustomerAddressUpdatedWorker
- type ErrorHandler
- type InitOrgBillingArgs
- type InitOrgBillingWorker
- type PaymentFailedArgs
- type PaymentFailedGracePeriodCheckArgs
- type PaymentFailedGracePeriodCheckWorker
- type PaymentFailedWorker
- type PaymentMethodAddedArgs
- type PaymentMethodAddedWorker
- type PaymentMethodRemovedArgs
- type PaymentMethodRemovedWorker
- type PaymentSuccessArgs
- type PaymentSuccessWorker
- type PurgeOrgArgs
- type PurgeOrgWorker
- type RepairOrgBillingArgs
- type RepairOrgBillingWorker
- type ResetAllDeploymentsArgs
- type ResetAllDeploymentsWorker
- type StartTrialArgs
- type StartTrialWorker
- type SubscriptionCancellationCheckArgs
- type SubscriptionCancellationCheckWorker
- type TrialEndCheckArgs
- type TrialEndCheckWorker
- type TrialEndingSoonArgs
- type TrialEndingSoonWorker
- type TrialGracePeriodCheckArgs
- type TrialGracePeriodCheckWorker
- type ValidateDeploymentsArgs
- type ValidateDeploymentsWorker
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) CustomerAddressUpdated ¶ added in v0.50.0
func (*Client) InitOrgBilling ¶ added in v0.50.0
func (*Client) PaymentFailed ¶ added in v0.50.0
func (*Client) PaymentMethodAdded ¶ added in v0.50.0
func (*Client) PaymentMethodRemoved ¶ added in v0.50.0
func (*Client) PaymentSuccess ¶ added in v0.50.0
func (*Client) RepairOrgBilling ¶ added in v0.50.0
func (*Client) ResetAllDeployments ¶
NOTE: Add new job trigger functions here
func (*Client) StartOrgTrial ¶ added in v0.50.0
type CustomerAddressUpdatedArgs ¶ added in v0.50.0
func (CustomerAddressUpdatedArgs) Kind ¶ added in v0.50.0
func (CustomerAddressUpdatedArgs) Kind() string
type CustomerAddressUpdatedWorker ¶ added in v0.50.0
type CustomerAddressUpdatedWorker struct { river.WorkerDefaults[CustomerAddressUpdatedArgs] // contains filtered or unexported fields }
func (*CustomerAddressUpdatedWorker) Work ¶ added in v0.50.0
func (w *CustomerAddressUpdatedWorker) Work(ctx context.Context, job *river.Job[CustomerAddressUpdatedArgs]) error
type ErrorHandler ¶
type ErrorHandler struct {
// contains filtered or unexported fields
}
func (*ErrorHandler) HandleError ¶
func (h *ErrorHandler) HandleError(ctx context.Context, job *rivertype.JobRow, err error) *river.ErrorHandlerResult
func (*ErrorHandler) HandlePanic ¶
func (h *ErrorHandler) HandlePanic(ctx context.Context, job *rivertype.JobRow, panicVal any, trace string) *river.ErrorHandlerResult
type InitOrgBillingArgs ¶ added in v0.50.0
type InitOrgBillingArgs struct {
OrgID string
}
func (InitOrgBillingArgs) Kind ¶ added in v0.50.0
func (InitOrgBillingArgs) Kind() string
type InitOrgBillingWorker ¶ added in v0.50.0
type InitOrgBillingWorker struct { river.WorkerDefaults[InitOrgBillingArgs] // contains filtered or unexported fields }
func (*InitOrgBillingWorker) Work ¶ added in v0.50.0
func (w *InitOrgBillingWorker) Work(ctx context.Context, job *river.Job[InitOrgBillingArgs]) error
Work This worker initializes the billing for an organization
type PaymentFailedArgs ¶ added in v0.50.0
type PaymentFailedArgs struct { BillingCustomerID string InvoiceID string InvoiceNumber string InvoiceURL string Amount string Currency string DueDate time.Time FailedAt time.Time }
func (PaymentFailedArgs) Kind ¶ added in v0.50.0
func (PaymentFailedArgs) Kind() string
type PaymentFailedGracePeriodCheckArgs ¶ added in v0.50.0
type PaymentFailedGracePeriodCheckArgs struct{}
func (PaymentFailedGracePeriodCheckArgs) Kind ¶ added in v0.50.0
func (PaymentFailedGracePeriodCheckArgs) Kind() string
type PaymentFailedGracePeriodCheckWorker ¶ added in v0.50.0
type PaymentFailedGracePeriodCheckWorker struct { river.WorkerDefaults[PaymentFailedGracePeriodCheckArgs] // contains filtered or unexported fields }
func (*PaymentFailedGracePeriodCheckWorker) Work ¶ added in v0.50.0
func (w *PaymentFailedGracePeriodCheckWorker) Work(ctx context.Context, job *river.Job[PaymentFailedGracePeriodCheckArgs]) error
type PaymentFailedWorker ¶ added in v0.50.0
type PaymentFailedWorker struct { river.WorkerDefaults[PaymentFailedArgs] // contains filtered or unexported fields }
func (*PaymentFailedWorker) Work ¶ added in v0.50.0
func (w *PaymentFailedWorker) Work(ctx context.Context, job *river.Job[PaymentFailedArgs]) error
type PaymentMethodAddedArgs ¶ added in v0.50.0
type PaymentMethodAddedArgs struct { PaymentMethodID string PaymentCustomerID string PaymentType string EventTime time.Time }
func (PaymentMethodAddedArgs) Kind ¶ added in v0.50.0
func (PaymentMethodAddedArgs) Kind() string
type PaymentMethodAddedWorker ¶ added in v0.50.0
type PaymentMethodAddedWorker struct { river.WorkerDefaults[PaymentMethodAddedArgs] // contains filtered or unexported fields }
func (*PaymentMethodAddedWorker) Work ¶ added in v0.50.0
func (w *PaymentMethodAddedWorker) Work(ctx context.Context, job *river.Job[PaymentMethodAddedArgs]) error
type PaymentMethodRemovedArgs ¶ added in v0.50.0
type PaymentMethodRemovedArgs struct { PaymentMethodID string PaymentCustomerID string EventTime time.Time }
func (PaymentMethodRemovedArgs) Kind ¶ added in v0.50.0
func (PaymentMethodRemovedArgs) Kind() string
type PaymentMethodRemovedWorker ¶ added in v0.50.0
type PaymentMethodRemovedWorker struct { river.WorkerDefaults[PaymentMethodRemovedArgs] // contains filtered or unexported fields }
func (*PaymentMethodRemovedWorker) Work ¶ added in v0.50.0
func (w *PaymentMethodRemovedWorker) Work(ctx context.Context, job *river.Job[PaymentMethodRemovedArgs]) error
type PaymentSuccessArgs ¶ added in v0.50.0
func (PaymentSuccessArgs) Kind ¶ added in v0.50.0
func (PaymentSuccessArgs) Kind() string
type PaymentSuccessWorker ¶ added in v0.50.0
type PaymentSuccessWorker struct { river.WorkerDefaults[PaymentSuccessArgs] // contains filtered or unexported fields }
func (*PaymentSuccessWorker) Work ¶ added in v0.50.0
func (w *PaymentSuccessWorker) Work(ctx context.Context, job *river.Job[PaymentSuccessArgs]) error
type PurgeOrgArgs ¶ added in v0.50.0
type PurgeOrgArgs struct {
OrgID string
}
func (PurgeOrgArgs) Kind ¶ added in v0.50.0
func (PurgeOrgArgs) Kind() string
type PurgeOrgWorker ¶ added in v0.50.0
type PurgeOrgWorker struct { river.WorkerDefaults[PurgeOrgArgs] // contains filtered or unexported fields }
func (*PurgeOrgWorker) Work ¶ added in v0.50.0
func (w *PurgeOrgWorker) Work(ctx context.Context, job *river.Job[PurgeOrgArgs]) error
Work This worker handles the deletion of an organization and all its associated data
type RepairOrgBillingArgs ¶ added in v0.50.0
type RepairOrgBillingArgs struct {
OrgID string
}
func (RepairOrgBillingArgs) Kind ¶ added in v0.50.0
func (RepairOrgBillingArgs) Kind() string
type RepairOrgBillingWorker ¶ added in v0.50.0
type RepairOrgBillingWorker struct { river.WorkerDefaults[RepairOrgBillingArgs] // contains filtered or unexported fields }
func (*RepairOrgBillingWorker) Work ¶ added in v0.50.0
func (w *RepairOrgBillingWorker) Work(ctx context.Context, job *river.Job[RepairOrgBillingArgs]) error
Work This worker repairs the billing for an organization
type ResetAllDeploymentsArgs ¶
type ResetAllDeploymentsArgs struct{}
func (ResetAllDeploymentsArgs) Kind ¶
func (ResetAllDeploymentsArgs) Kind() string
type ResetAllDeploymentsWorker ¶
type ResetAllDeploymentsWorker struct { river.WorkerDefaults[ResetAllDeploymentsArgs] // contains filtered or unexported fields }
func (*ResetAllDeploymentsWorker) Work ¶
func (w *ResetAllDeploymentsWorker) Work(ctx context.Context, job *river.Job[ResetAllDeploymentsArgs]) error
type StartTrialArgs ¶ added in v0.50.0
type StartTrialArgs struct {
OrgID string
}
func (StartTrialArgs) Kind ¶ added in v0.50.0
func (StartTrialArgs) Kind() string
type StartTrialWorker ¶ added in v0.50.0
type StartTrialWorker struct { river.WorkerDefaults[StartTrialArgs] // contains filtered or unexported fields }
func (*StartTrialWorker) Work ¶ added in v0.50.0
func (w *StartTrialWorker) Work(ctx context.Context, job *river.Job[StartTrialArgs]) error
Work This worker starts the trial for an organization
type SubscriptionCancellationCheckArgs ¶ added in v0.50.0
type SubscriptionCancellationCheckArgs struct{}
func (SubscriptionCancellationCheckArgs) Kind ¶ added in v0.50.0
func (SubscriptionCancellationCheckArgs) Kind() string
type SubscriptionCancellationCheckWorker ¶ added in v0.50.0
type SubscriptionCancellationCheckWorker struct { river.WorkerDefaults[SubscriptionCancellationCheckArgs] // contains filtered or unexported fields }
func (*SubscriptionCancellationCheckWorker) Work ¶ added in v0.50.0
func (w *SubscriptionCancellationCheckWorker) Work(ctx context.Context, job *river.Job[SubscriptionCancellationCheckArgs]) error
Work This worker runs at end of the current subscription term after subscription cancellation
type TrialEndCheckArgs ¶ added in v0.50.0
type TrialEndCheckArgs struct{}
func (TrialEndCheckArgs) Kind ¶ added in v0.50.0
func (TrialEndCheckArgs) Kind() string
type TrialEndCheckWorker ¶ added in v0.50.0
type TrialEndCheckWorker struct { river.WorkerDefaults[TrialEndCheckArgs] // contains filtered or unexported fields }
func (*TrialEndCheckWorker) Work ¶ added in v0.50.0
func (w *TrialEndCheckWorker) Work(ctx context.Context, job *river.Job[TrialEndCheckArgs]) error
type TrialEndingSoonArgs ¶ added in v0.50.0
type TrialEndingSoonArgs struct{}
func (TrialEndingSoonArgs) Kind ¶ added in v0.50.0
func (TrialEndingSoonArgs) Kind() string
type TrialEndingSoonWorker ¶ added in v0.50.0
type TrialEndingSoonWorker struct { river.WorkerDefaults[TrialEndingSoonArgs] // contains filtered or unexported fields }
func (*TrialEndingSoonWorker) Work ¶ added in v0.50.0
func (w *TrialEndingSoonWorker) Work(ctx context.Context, job *river.Job[TrialEndingSoonArgs]) error
type TrialGracePeriodCheckArgs ¶ added in v0.50.0
type TrialGracePeriodCheckArgs struct{}
func (TrialGracePeriodCheckArgs) Kind ¶ added in v0.50.0
func (TrialGracePeriodCheckArgs) Kind() string
type TrialGracePeriodCheckWorker ¶ added in v0.50.0
type TrialGracePeriodCheckWorker struct { river.WorkerDefaults[TrialGracePeriodCheckArgs] // contains filtered or unexported fields }
func (*TrialGracePeriodCheckWorker) Work ¶ added in v0.50.0
func (w *TrialGracePeriodCheckWorker) Work(ctx context.Context, job *river.Job[TrialGracePeriodCheckArgs]) error
type ValidateDeploymentsArgs ¶
type ValidateDeploymentsArgs struct{}
func (ValidateDeploymentsArgs) Kind ¶
func (ValidateDeploymentsArgs) Kind() string
type ValidateDeploymentsWorker ¶
type ValidateDeploymentsWorker struct { river.WorkerDefaults[ValidateDeploymentsArgs] // contains filtered or unexported fields }
func (*ValidateDeploymentsWorker) Work ¶
func (w *ValidateDeploymentsWorker) Work(ctx context.Context, job *river.Job[ValidateDeploymentsArgs]) error
Click to show internal directories.
Click to hide internal directories.