Skip to content

Commit

Permalink
Use adjusted 'UpsertStreamed' and 'DeleteStreamed' from icinga-go-lib…
Browse files Browse the repository at this point in the history
…rary
  • Loading branch information
jrauh01 committed Nov 24, 2023
1 parent 771ef0a commit 7333404
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/sync/logs.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ func (ls *LogSync) MaintainList(ctx context.Context, addChannel <-chan contracts
})

g.Go(func() error {
return ls.db.DeleteStreamedByField(ctx, &schema.Log{}, "reference_id", deletes)
return ls.db.DeleteStreamed(ctx, &schema.Log{}, deletes, database.ByColumn("reference_id"))
})

return g.Wait()
Expand Down Expand Up @@ -224,7 +224,7 @@ func (ls *LogSync) Run(ctx context.Context) error {
})

g.Go(func() error {
return ls.db.UpsertStreamedWithStatement(ctx, upserts, upsertStmt, 5)
return ls.db.UpsertStreamed(ctx, upserts, database.WithStatement(upsertStmt, 5))
})

return g.Wait()
Expand Down

0 comments on commit 7333404

Please sign in to comment.