Documentation
¶
Index ¶
- type CronLog
- type CronPlan
- type CronStore
- func (s *CronStore) CheckPlanExists(instanceName string) (bool, error)
- func (s *CronStore) CompleteLog(logID int) error
- func (s *CronStore) CreateLog(instanceName string) (*CronLog, error)
- func (s *CronStore) CreatePlan(instanceName string, utcHour, cleanupLocalDays, cleanupRemoteDays int) error
- func (s *CronStore) DeletePlan(instanceName string) error
- func (s *CronStore) GetAllPlans() ([]*CronPlan, error)
- func (s *CronStore) GetLatestLogForInstance(instanceName string) (*CronLog, error)
- func (s *CronStore) GetPlan(instanceName string) (*CronPlan, error)
- func (s *CronStore) GetPlansForHour(utcHour int) ([]*CronPlan, error)
- func (s *CronStore) HasRunInLastHour(instanceName string) (bool, error)
- func (s *CronStore) ListLogs(instanceName string, limit int) ([]*CronLog, error)
- func (s *CronStore) ListPlans() ([]*CronPlan, error)
- func (s *CronStore) UpdateLog(logID int, updates map[string]any) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CronLog ¶
type CronLog struct {
ID int `db:"id" json:"id,omitempty"`
InstanceName string `db:"instance_name" json:"instanceName"`
StartedAt rfc3339time.Time `db:"started_at" json:"startedAt"`
CompletedAt *rfc3339time.Time `db:"completed_at" json:"completedAt,omitempty"`
BackupStatus *string `db:"backup_status" json:"backupStatus,omitempty"`
BackupFinishedAt *rfc3339time.Time `db:"backup_finished_at" json:"backupFinishedAt,omitempty"`
BackupError *string `db:"backup_error" json:"backupError,omitempty"`
BackupUploadStatus *string `db:"backup_upload_status" json:"backupUploadStatus,omitempty"`
BackupUploadFinishedAt *rfc3339time.Time `db:"backup_upload_finished_at" json:"backupUploadFinishedAt,omitempty"`
BackupUploadError *string `db:"backup_upload_error" json:"backupUploadError,omitempty"`
BackupCleanupStatus *string `db:"backup_cleanup_status" json:"backupCleanupStatus,omitempty"`
BackupCleanupFinishedAt *rfc3339time.Time `db:"backup_cleanup_finished_at" json:"backupCleanupFinishedAt,omitempty"`
BackupCleanupError *string `db:"backup_cleanup_error" json:"backupCleanupError,omitempty"`
BackupRemoteCleanupStatus *string `db:"backup_remote_cleanup_status" json:"backupRemoteCleanupStatus,omitempty"`
BackupRemoteCleanupFinishedAt *rfc3339time.Time `db:"backup_remote_cleanup_finished_at" json:"backupRemoteCleanupFinishedAt,omitempty"`
BackupRemoteCleanupError *string `db:"backup_remote_cleanup_error" json:"backupRemoteCleanupError,omitempty"`
}
type CronPlan ¶
type CronPlan struct {
InstanceName string `db:"instance_name" json:"instanceName"`
UTCHour int `db:"utc_hour" json:"utcHour"`
CleanupLocalDays int `db:"cleanup_local_days" json:"cleanupLocalDays"`
CleanupRemoteDays int `db:"cleanup_remote_days" json:"cleanupRemoteDays"`
CreatedAt rfc3339time.Time `db:"created_at" json:"createdAt"`
UpdatedAt rfc3339time.Time `db:"updated_at" json:"updatedAt"`
}
type CronStore ¶
type CronStore struct {
// contains filtered or unexported fields
}
func NewCronStore ¶
func (*CronStore) CheckPlanExists ¶
func (*CronStore) CompleteLog ¶
func (*CronStore) CreatePlan ¶
func (*CronStore) DeletePlan ¶
func (*CronStore) GetAllPlans ¶
func (*CronStore) GetLatestLogForInstance ¶
func (*CronStore) GetPlansForHour ¶
func (*CronStore) HasRunInLastHour ¶
Click to show internal directories.
Click to hide internal directories.