Documentation ¶
Index ¶
Constants ¶
View Source
const (
FieldMaskContent = "content"
)
View Source
const OfferingAggregateType = "offering"
View Source
const (
OfferingCreateV1 = "V1_OFFERING_CREATE"
)
Variables ¶
This section is empty.
Functions ¶
func GetOfferingObjectID ¶
Types ¶
type OfferingAggregate ¶
type OfferingAggregate struct { *aggregate.CommonTenantIdAggregate Offering *Offering }
func LoadOfferingAggregate ¶
func LoadOfferingAggregate(ctx context.Context, eventStore eventstore.AggregateStore, tenant, objectID string, opts eventstore.LoadAggregateOptions) (*OfferingAggregate, error)
func NewOfferingAggregateWithTenantAndID ¶
func NewOfferingAggregateWithTenantAndID(tenant, id string) *OfferingAggregate
func (*OfferingAggregate) CreateOffering ¶
func (a *OfferingAggregate) CreateOffering(ctx context.Context, request *offeringpb.CreateOfferingGrpcRequest) error
func (*OfferingAggregate) HandleRequest ¶
func (*OfferingAggregate) When ¶
func (a *OfferingAggregate) When(event eventstore.Event) error
type OfferingCreateEvent ¶
type OfferingCreateEvent struct {
Tenant string `json:"tenant" validate:"required"`
}
type OfferingRequestHandler ¶
type OfferingRequestHandler interface { Handle(ctx context.Context, tenant, objectId string, request any, params ...map[string]any) (any, error) HandleWithRetry(ctx context.Context, tenant, objectId string, aggregateRequired bool, request any, params ...map[string]any) (any, error) }
func NewOfferingRequestHandler ¶
func NewOfferingRequestHandler(log logger.Logger, es eventstore.AggregateStore, cfg config.Utils) OfferingRequestHandler
Click to show internal directories.
Click to hide internal directories.