Documentation
¶
Overview ¶
Package requestlog retains request occurrences and projects request status read models.
Index ¶
Constants ¶
View Source
const ( // MetadataKeyBuildID identifies the build associated with a request event. MetadataKeyBuildID = "build_id" // MetadataKeyFactDegree records the degree established by a validation fact. MetadataKeyFactDegree = "fact_degree" // MetadataKeyProjectFactCount records how many project facts a completed batch established. MetadataKeyProjectFactCount = "project_fact_count" // MetadataKeyBaseURI records the selected build baseline; an empty value means a full build. MetadataKeyBaseURI = "base_uri" )
Variables ¶
This section is empty.
Functions ¶
func NewRequestEventLog ¶
func NewRequestEventLog( request entity.Request, event entity.RequestEvent, occurrence string, metadata map[string]string, ) entity.RequestLog
NewRequestEventLog constructs a stable occurrence for a durable request lifecycle event.
func NewRequestStateLog ¶
func NewRequestStateLog(request entity.Request, outcomeReason entity.RequestOutcomeReason) entity.RequestLog
NewRequestStateLog constructs the occurrence representing the request's current durable state.
Types ¶
type Materializer ¶
type Materializer interface {
// PersistLog retains one occurrence idempotently and updates projections derived from it.
PersistLog(context.Context, storage.Storage, entity.RequestLog) error
}
Materializer retains request-log occurrences and advances their derived read models.
func NewMaterializer ¶
func NewMaterializer(scope tally.Scope) Materializer
NewMaterializer creates a request-log materializer.
Click to show internal directories.
Click to hide internal directories.