refactor(eventstore): rename EventPusher to Command, EventReader to Event, PushEvents to Push and FilterEvents to Filter (#2907)

This commit is contained in:
Silvan
2022-01-03 09:19:07 +01:00
committed by GitHub
parent 9a374f9c5c
commit 09be70949f
339 changed files with 1436 additions and 1346 deletions

View File

@@ -3,9 +3,10 @@ package user
import (
"context"
"encoding/json"
"github.com/caos/zitadel/internal/eventstore"
"time"
"github.com/caos/zitadel/internal/eventstore"
"github.com/caos/zitadel/internal/crypto"
"github.com/caos/zitadel/internal/domain"
"github.com/caos/zitadel/internal/errors"
@@ -56,7 +57,7 @@ func NewHumanPasswordChangedEvent(
}
}
func HumanPasswordChangedEventMapper(event *repository.Event) (eventstore.EventReader, error) {
func HumanPasswordChangedEventMapper(event *repository.Event) (eventstore.Event, error) {
humanAdded := &HumanPasswordChangedEvent{
BaseEvent: *eventstore.BaseEventFromRepo(event),
}
@@ -103,7 +104,7 @@ func NewHumanPasswordCodeAddedEvent(
}
}
func HumanPasswordCodeAddedEventMapper(event *repository.Event) (eventstore.EventReader, error) {
func HumanPasswordCodeAddedEventMapper(event *repository.Event) (eventstore.Event, error) {
humanAdded := &HumanPasswordCodeAddedEvent{
BaseEvent: *eventstore.BaseEventFromRepo(event),
}
@@ -137,7 +138,7 @@ func NewHumanPasswordCodeSentEvent(ctx context.Context, aggregate *eventstore.Ag
}
}
func HumanPasswordCodeSentEventMapper(event *repository.Event) (eventstore.EventReader, error) {
func HumanPasswordCodeSentEventMapper(event *repository.Event) (eventstore.Event, error) {
return &HumanPasswordCodeSentEvent{
BaseEvent: *eventstore.BaseEventFromRepo(event),
}, nil
@@ -171,7 +172,7 @@ func NewHumanPasswordCheckSucceededEvent(
}
}
func HumanPasswordCheckSucceededEventMapper(event *repository.Event) (eventstore.EventReader, error) {
func HumanPasswordCheckSucceededEventMapper(event *repository.Event) (eventstore.Event, error) {
humanAdded := &HumanPasswordCheckSucceededEvent{
BaseEvent: *eventstore.BaseEventFromRepo(event),
}
@@ -211,7 +212,7 @@ func NewHumanPasswordCheckFailedEvent(
}
}
func HumanPasswordCheckFailedEventMapper(event *repository.Event) (eventstore.EventReader, error) {
func HumanPasswordCheckFailedEventMapper(event *repository.Event) (eventstore.Event, error) {
humanAdded := &HumanPasswordCheckFailedEvent{
BaseEvent: *eventstore.BaseEventFromRepo(event),
}