Documentation ¶
Index ¶
- Variables
- type PaginateWebhookExecutionsParams
- type PaginateWebhooksParams
- type Service
- func (s *Service) CreateWebhook(ctx context.Context, params dbgen.WebhooksServiceCreateWebhookParams) (dbgen.Webhook, error)
- func (s *Service) DeleteWebhook(ctx context.Context, id uuid.UUID) error
- func (s *Service) DuplicateWebhook(ctx context.Context, webhookID uuid.UUID) (dbgen.Webhook, error)
- func (s *Service) GetWebhook(ctx context.Context, id uuid.UUID) (dbgen.Webhook, error)
- func (s *Service) PaginateWebhookExecutions(ctx context.Context, params PaginateWebhookExecutionsParams) (paginateutil.PaginateResponse, []dbgen.WebhookExecution, error)
- func (s *Service) PaginateWebhooks(ctx context.Context, params PaginateWebhooksParams) (paginateutil.PaginateResponse, []dbgen.Webhook, error)
- func (s *Service) RunDatabaseHealthy(databaseID uuid.UUID)
- func (s *Service) RunDatabaseUnhealthy(databaseID uuid.UUID)
- func (s *Service) RunDestinationHealthy(destinationID uuid.UUID)
- func (s *Service) RunDestinationUnhealthy(destinationID uuid.UUID)
- func (s *Service) RunExecutionFailed(backupID uuid.UUID)
- func (s *Service) RunExecutionSuccess(backupID uuid.UUID)
- func (s *Service) SendWebhookRequest(ctx context.Context, webhook dbgen.Webhook) error
- func (s *Service) UpdateWebhook(ctx context.Context, params dbgen.WebhooksServiceUpdateWebhookParams) (dbgen.Webhook, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( EventTypeDatabaseHealthy = eventType{ Value: eventTypeData{Key: "database_healthy", Name: "Database healthy"}, } EventTypeDatabaseUnhealthy = eventType{ Value: eventTypeData{Key: "database_unhealthy", Name: "Database unhealthy"}, } EventTypeDestinationHealthy = eventType{ Value: eventTypeData{Key: "destination_healthy", Name: "Destination healthy"}, } EventTypeDestinationUnhealthy = eventType{ Value: eventTypeData{Key: "destination_unhealthy", Name: "Destination unhealthy"}, } EventTypeExecutionSuccess = eventType{ Value: eventTypeData{Key: "execution_success", Name: "Execution success"}, } EventTypeExecutionFailed = eventType{ Value: eventTypeData{Key: "execution_failed", Name: "Execution failed"}, } )
View Source
var FullEventTypes = map[string]string{ EventTypeDatabaseHealthy.Value.Key: EventTypeDatabaseHealthy.Value.Name, EventTypeDatabaseUnhealthy.Value.Key: EventTypeDatabaseUnhealthy.Value.Name, EventTypeDestinationHealthy.Value.Key: EventTypeDestinationHealthy.Value.Name, EventTypeDestinationUnhealthy.Value.Key: EventTypeDestinationUnhealthy.Value.Name, EventTypeExecutionSuccess.Value.Key: EventTypeExecutionSuccess.Value.Name, EventTypeExecutionFailed.Value.Key: EventTypeExecutionFailed.Value.Name, }
Functions ¶
This section is empty.
Types ¶
type PaginateWebhooksParams ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) CreateWebhook ¶
func (*Service) DeleteWebhook ¶
func (*Service) DuplicateWebhook ¶
func (*Service) GetWebhook ¶
func (*Service) PaginateWebhookExecutions ¶
func (s *Service) PaginateWebhookExecutions( ctx context.Context, params PaginateWebhookExecutionsParams, ) (paginateutil.PaginateResponse, []dbgen.WebhookExecution, error)
func (*Service) PaginateWebhooks ¶
func (s *Service) PaginateWebhooks( ctx context.Context, params PaginateWebhooksParams, ) (paginateutil.PaginateResponse, []dbgen.Webhook, error)
func (*Service) RunDatabaseHealthy ¶
RunDatabaseHealthy runs the healthy webhooks for the given database ID.
func (*Service) RunDatabaseUnhealthy ¶
RunDatabaseUnhealthy runs the unhealthy webhooks for the given database ID.
func (*Service) RunDestinationHealthy ¶
RunDestinationHealthy runs the healthy webhooks for the given destination ID.
func (*Service) RunDestinationUnhealthy ¶
RunDestinationUnhealthy runs the unhealthy webhooks for the given destination ID.
func (*Service) RunExecutionFailed ¶
RunExecutionFailed runs the failed webhooks for the given execution ID.
func (*Service) RunExecutionSuccess ¶
RunExecutionSuccess runs the success webhooks for the given execution ID.
func (*Service) SendWebhookRequest ¶
SendWebhookRequest sends a webhook request to the given webhook and stores the result in the database.
func (*Service) UpdateWebhook ¶
Click to show internal directories.
Click to hide internal directories.