Derive artifact catalogs from the selected party without changing configuration
This commit is contained in:
@@ -14,9 +14,10 @@ type Config struct {
|
||||
CampaignDocument *CampaignConfig
|
||||
SessionDocument *SessionConfig
|
||||
|
||||
StableInputs ResolvedStableInputs
|
||||
SessionSource SessionSource
|
||||
Party ResolvedParty
|
||||
StableInputs ResolvedStableInputs
|
||||
SessionSource SessionSource
|
||||
Party ResolvedParty
|
||||
ArtifactCatalog *ArtifactCatalog
|
||||
}
|
||||
|
||||
// PipelineConfig contains durable pipeline-level settings.
|
||||
@@ -37,16 +38,24 @@ type PipelineConfig struct {
|
||||
Notarius *NotariusConfig `yaml:"notarius" json:"notarius"`
|
||||
Notification NotificationConfig `yaml:"notification" json:"notification"`
|
||||
|
||||
resolution *pipelineResolutionMetadata `yaml:"-" json:"-"`
|
||||
familyCatalog ArtifactFamilyCatalog `yaml:"-" json:"-"`
|
||||
resolution *pipelineResolutionMetadata `yaml:"-" json:"-"`
|
||||
}
|
||||
|
||||
// ArtifactFamilies returns a copy of runtime-only expansion provenance.
|
||||
func ArtifactFamilies(cfg *PipelineConfig) ArtifactFamilyCatalog {
|
||||
if cfg == nil {
|
||||
// ArtifactCatalog contains domain products derived from completed pipeline
|
||||
// configuration and one selected canonical roster.
|
||||
type ArtifactCatalog struct {
|
||||
Artifacts map[string]ScriptoriumArtifactConfig
|
||||
Families ArtifactFamilyCatalog
|
||||
PublishOutputs []PublishOutputRule
|
||||
Records []EffectiveArtifactRecord
|
||||
}
|
||||
|
||||
// ArtifactFamilies returns a copy of the derived family/member provenance.
|
||||
func ArtifactFamilies(catalog *ArtifactCatalog) ArtifactFamilyCatalog {
|
||||
if catalog == nil {
|
||||
return ArtifactFamilyCatalog{}
|
||||
}
|
||||
return cloneArtifactFamilyCatalog(cfg.familyCatalog)
|
||||
return cloneArtifactFamilyCatalog(catalog.Families)
|
||||
}
|
||||
|
||||
// CampaignsConfig configures the local campaign registry.
|
||||
@@ -350,8 +359,7 @@ type SessionAudioS3Input struct {
|
||||
Prefix string `yaml:"prefix" json:"prefix"`
|
||||
}
|
||||
|
||||
// ResolvedStableInputs records where stable input file paths came from after
|
||||
// campaign/session merge.
|
||||
// ResolvedStableInputs records the origins of completed stable input paths.
|
||||
type ResolvedStableInputs struct {
|
||||
SpeakersFile ResolvedInputFile
|
||||
AutocorrectFile ResolvedInputFile
|
||||
@@ -360,19 +368,20 @@ type ResolvedStableInputs struct {
|
||||
SpellCatalogFile ResolvedInputFile
|
||||
}
|
||||
|
||||
// ResolvedInputFile records one merged config path and its source config file.
|
||||
// ResolvedInputFile records one effective input path and its declaring source.
|
||||
type ResolvedInputFile struct {
|
||||
Path string
|
||||
ConfigPath string
|
||||
Source string
|
||||
}
|
||||
|
||||
// ResolvedParty records the campaign-owned canonical party and its non-secret
|
||||
// ResolvedParty records the selected canonical party and its non-secret
|
||||
// source provenance. It is runtime-only and must never be copied into manifests
|
||||
// as raw party content.
|
||||
type ResolvedParty struct {
|
||||
Source PartySource
|
||||
Canonical *CanonicalParty
|
||||
Players []byte
|
||||
}
|
||||
|
||||
// PartySource identifies the selected party input without retaining its raw
|
||||
|
||||
Reference in New Issue
Block a user