@@ -139,9 +139,11 @@ type DataStreamManifest struct {
139139 Hidden bool `config:"hidden" json:"hidden" yaml:"hidden"`
140140 Release string `config:"release" json:"release" yaml:"release"`
141141 Elasticsearch * struct {
142- IngestPipeline * struct {
143- Name string `config:"name" json:"name" yaml:"name"`
144- } `config:"ingest_pipeline" json:"ingest_pipeline" yaml:"ingest_pipeline"`
142+ IndexTemplate * struct {
143+ IngestPipeline * struct {
144+ Name string `config:"name" json:"name" yaml:"name"`
145+ } `config:"ingest_pipeline" json:"ingest_pipeline" yaml:"ingest_pipeline"`
146+ } `config:"index_template" json:"index_template" yaml:"index_template"`
145147 } `config:"elasticsearch" json:"elasticsearch" yaml:"elasticsearch"`
146148 Streams []struct {
147149 Input string `config:"input" json:"input" yaml:"input"`
@@ -255,8 +257,8 @@ func ReadDataStreamManifest(path string) (*DataStreamManifest, error) {
255257// GetPipelineNameOrDefault returns the name of the data stream's pipeline, if one is explicitly defined in the
256258// data stream manifest. If not, the default pipeline name is returned.
257259func (dsm * DataStreamManifest ) GetPipelineNameOrDefault () string {
258- if dsm .Elasticsearch != nil && dsm .Elasticsearch .IngestPipeline != nil && dsm .Elasticsearch .IngestPipeline .Name != "" {
259- return dsm .Elasticsearch .IngestPipeline .Name
260+ if dsm .Elasticsearch != nil && dsm .Elasticsearch .IndexTemplate != nil && dsm . Elasticsearch . IndexTemplate . IngestPipeline != nil && dsm .Elasticsearch . IndexTemplate .IngestPipeline .Name != "" {
261+ return dsm .Elasticsearch .IndexTemplate . IngestPipeline .Name
260262 }
261263 return defaultPipelineName
262264}
0 commit comments