mirror of
https://github.com/zitadel/zitadel.git
synced 2025-10-09 11:12:01 +00:00
feat: sequence and timestamp on searchrequests (#468)
* feat: reread events * feat: sequence and timestamo on search requests * feat: sequence and timestamo on search requests * fix: better naming * fix: log errors * fix: read sequence before search request
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
package admin
|
||||
|
||||
import (
|
||||
"github.com/caos/logging"
|
||||
view_model "github.com/caos/zitadel/internal/view/model"
|
||||
"github.com/caos/zitadel/pkg/grpc/admin"
|
||||
"github.com/golang/protobuf/ptypes"
|
||||
)
|
||||
|
||||
func viewsFromModel(views []*view_model.View) []*admin.View {
|
||||
@@ -24,10 +26,14 @@ func failedEventsFromModel(failedEvents []*view_model.FailedEvent) []*admin.Fail
|
||||
}
|
||||
|
||||
func viewFromModel(view *view_model.View) *admin.View {
|
||||
timestamp, err := ptypes.TimestampProto(view.CurrentTimestamp)
|
||||
logging.Log("GRPC-KSo03").OnError(err).Debug("unable to parse timestamp")
|
||||
|
||||
return &admin.View{
|
||||
Database: view.Database,
|
||||
ViewName: view.ViewName,
|
||||
Sequence: view.CurrentSequence,
|
||||
Database: view.Database,
|
||||
ViewName: view.ViewName,
|
||||
ProcessedSequence: view.CurrentSequence,
|
||||
ViewTimestamp: timestamp,
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user