mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 19:07:30 +00:00
new pkg structure (#1150)
* fix: split command query side * fix: split command query side * fix: members in correct pkg structure * fix: label policy in correct pkg structure * fix: structure * fix: structure of login policy * fix: identityprovider structure * fix: org iam policy structure * fix: password age policy structure * fix: password complexity policy structure * fix: password lockout policy structure * fix: idp structure * fix: user events structure * fix: user write model * fix: profile email changed command * fix: address changed command * fix: user states * fix: user * fix: org structure and add human * begin iam setup command side * setup * step2 * step2 * fix: add user * step2 * isvalid * fix: folder structure v2 business Co-authored-by: Fabiennne <fabienne.gerschwiler@gmail.com>
This commit is contained in:
@@ -3,7 +3,7 @@ package eventstore
|
||||
type aggregater interface {
|
||||
//ID returns the aggreagte id
|
||||
ID() string
|
||||
//Type returns the aggregate type
|
||||
//KeyType returns the aggregate type
|
||||
Type() AggregateType
|
||||
//Events returns the events which will be pushed
|
||||
Events() []EventPusher
|
||||
@@ -74,7 +74,7 @@ func (a *Aggregate) ID() string {
|
||||
return a.id
|
||||
}
|
||||
|
||||
//Type implements aggregater
|
||||
//KeyType implements aggregater
|
||||
func (a *Aggregate) Type() AggregateType {
|
||||
return a.typ
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ type EventPusher interface {
|
||||
EditorService() string
|
||||
//EditorUser is the user who wants to push the event
|
||||
EditorUser() string
|
||||
//Type must return an event type which should be unique in the aggregate
|
||||
//KeyType must return an event type which should be unique in the aggregate
|
||||
Type() EventType
|
||||
//Data returns the payload of the event. It represent the changed fields by the event
|
||||
// valid types are:
|
||||
@@ -25,7 +25,7 @@ type EventReader interface {
|
||||
EditorService() string
|
||||
//EditorUser is the user who pushed the event
|
||||
EditorUser() string
|
||||
//Type is the type of the event
|
||||
//KeyType is the type of the event
|
||||
Type() EventType
|
||||
|
||||
AggregateID() string
|
||||
|
@@ -36,7 +36,7 @@ func (e *BaseEvent) EditorUser() string {
|
||||
return e.User
|
||||
}
|
||||
|
||||
//Type implements EventPusher
|
||||
//KeyType implements EventPusher
|
||||
func (e *BaseEvent) Type() EventType {
|
||||
return e.EventType
|
||||
}
|
||||
|
@@ -6,7 +6,7 @@ import (
|
||||
"log"
|
||||
)
|
||||
|
||||
//ReadModel is the minimum representation of a View model.
|
||||
//MemberReadModel is the minimum representation of a View model.
|
||||
// it might be saved in a database or in memory
|
||||
type ReadModel struct {
|
||||
ProcessedSequence uint64
|
||||
|
@@ -2,7 +2,7 @@ package eventstore
|
||||
|
||||
import "time"
|
||||
|
||||
//ReadModel is the minimum representation of a View model.
|
||||
//MemberReadModel is the minimum representation of a View model.
|
||||
// It implements a basic reducer
|
||||
// it might be saved in a database or in memory
|
||||
type ReadModel struct {
|
||||
|
@@ -26,7 +26,7 @@ type Event struct {
|
||||
// time drifts in different services could cause integrity problems
|
||||
CreationDate time.Time
|
||||
|
||||
//Type describes the cause of the event (e.g. user.added)
|
||||
//KeyType describes the cause of the event (e.g. user.added)
|
||||
// it should always be in past-form
|
||||
Type EventType
|
||||
|
||||
|
@@ -2,7 +2,7 @@ package eventstore
|
||||
|
||||
import "time"
|
||||
|
||||
//WriteModel is the minimum representation of a command side view model.
|
||||
//MemberWriteModel is the minimum representation of a command side view model.
|
||||
// It implements a basic reducer
|
||||
// it's purpose is to reduce events to create new ones
|
||||
type WriteModel struct {
|
||||
|
Reference in New Issue
Block a user