mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-13 19:44:21 +00:00
e8babf1048
* fix: reduce load on view tables * create prerelease * linting: pass context to view handlers * fix error handling of refresh token handler * fix: improve processing of successful instanceIDs on views * fix revert intended change in .golangci.yaml * fix: set timeout for processInstances in spooler * fix: reduce update to active tokens on profile change * change token expiration query to db now() * remove branch from .releaserc.js
19 lines
582 B
Go
19 lines
582 B
Go
package view
|
|
|
|
import (
|
|
"github.com/zitadel/zitadel/internal/eventstore/v1/models"
|
|
"github.com/zitadel/zitadel/internal/view/repository"
|
|
)
|
|
|
|
const (
|
|
sequencesTable = "auth.current_sequences"
|
|
)
|
|
|
|
func (v *View) saveCurrentSequence(viewName string, event *models.Event) error {
|
|
return repository.SaveCurrentSequence(v.Db, sequencesTable, viewName, event.InstanceID, event.Sequence, event.CreationDate)
|
|
}
|
|
|
|
func (v *View) latestSequence(viewName, instanceID string) (*repository.CurrentSequence, error) {
|
|
return repository.LatestSequence(v.Db, sequencesTable, viewName, instanceID)
|
|
}
|