mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-13 11:34:26 +00:00
a6c4702b8e
* start sub * start implement subsciptions * start subscription * implementation for member done * admin done * fix: tests * extend handlers * prepary notification * no errors in adminapi * changed current sequence in all packages * ignore mocks * works * subscriptions as singleton * tests * refactor: rename function scope var * fix: process ALL previous sequences * fix: spooler and pubsub * handler check * fix: process events until all done * fix break on query err * fix: handler * fix: process sequence or return error * check aggregate id * fix: log only in error case * fix tests * fix: handlers * fix: spooler * fix: spooler * fix: tests * fix: continue * fix: locker duration * fix: variable lock duration * fix: test * fix: test * fix: test min max time Co-authored-by: Livio Amstutz <livio.a@gmail.com>
20 lines
363 B
Go
20 lines
363 B
Go
package spooler
|
|
|
|
import (
|
|
"database/sql"
|
|
es_locker "github.com/caos/zitadel/internal/eventstore/locker"
|
|
"time"
|
|
)
|
|
|
|
const (
|
|
lockTable = "adminapi.locks"
|
|
)
|
|
|
|
type locker struct {
|
|
dbClient *sql.DB
|
|
}
|
|
|
|
func (l *locker) Renew(lockerID, viewModel string, waitTime time.Duration) error {
|
|
return es_locker.Renew(l.dbClient, lockTable, lockerID, viewModel, waitTime)
|
|
}
|