Skip to content

Commit

Permalink
fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
garden-of-delete committed Mar 22, 2024
1 parent 4938856 commit 51c2eb0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions service/cleanup.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func (s *Cleanup) Run() {

func (s *Cleanup) deleteExpiredActivatorLocks(db *gorm.DB) {
expiryTime := time.Now().Add(-s.WorkflowActivationLockTimeout)
fmt.Printf("Deleting activation locks older than $s ...\n", expiryTime)
fmt.Printf("Deleting activation locks older than %s ...\n", expiryTime)

db.Model(&table.WorkflowActivatorLock{}).
Where("lock_time < ?", expiryTime).
Expand All @@ -33,7 +33,7 @@ func (s *Cleanup) deleteExpiredActivatorLocks(db *gorm.DB) {

func (s *Cleanup) deleteExpiredSchedulerLocks(db *gorm.DB) {
expiryTime := time.Now().Add(-s.WorkflowSchedulerLockTimeout)
fmt.Printf("Deleting scheduler locks older than $s ...\n", expiryTime)
fmt.Printf("Deleting scheduler locks older than %s ...\n", expiryTime)

db.Model(&table.WorkflowSchedulerLock{}).
Where("lock_time < ?", expiryTime).
Expand All @@ -42,7 +42,7 @@ func (s *Cleanup) deleteExpiredSchedulerLocks(db *gorm.DB) {

func (s *Cleanup) deleteExpiredScheduledWorkflows(db *gorm.DB) {
expiryTime := time.Now().Add(-s.ScheduledWorkflowTimeout)
fmt.Printf("Deleting scheduled workflows older than $s ...\n", expiryTime)
fmt.Printf("Deleting scheduled workflows older than %s ...\n", expiryTime)

db.Unscoped().Model(&table.ScheduledWorkflow{}).
Where("updated_at < ?", expiryTime).
Expand Down

0 comments on commit 51c2eb0

Please sign in to comment.