incidentuc

package
v0.2.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 28, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package incidentuc is the usecase seam over the event-sourced incident store.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(store ports.IncidentEventStore) (*Service, error)

func (*Service) Append

func (s *Service) Append(ctx context.Context, id shared.ID, expectedRevision int, events []incident.IncidentEvent) (incident.Incident, error)

Append resolves aliases and rewrites all incoming event identities to the canonical root before validation.

func (*Service) Get

func (s *Service) Get(ctx context.Context, id shared.ID) (incident.Incident, error)

Get returns the canonical logical projection for either a root or a historical alias. Root workflow fields remain root-owned; immutable member evidence is unioned deterministically for the read model.

func (*Service) ListByAsset

func (s *Service) ListByAsset(ctx context.Context, asset shared.ID, limit int) ([]incident.Incident, error)
func (s *Service) ListPendingResponseLinks(ctx context.Context) ([]incident.ResponseLink, error)

func (*Service) RecordCorrelation

func (s *Service) RecordCorrelation(ctx context.Context, events []incident.IncidentEvent) (created, updated []incident.Incident, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL