Skip to content

Add pipeline reference example to coredns#108

Merged
ruflin merged 1 commit intoelastic:masterfrom
ruflin:pipeline-example
Sep 25, 2019
Merged

Add pipeline reference example to coredns#108
ruflin merged 1 commit intoelastic:masterfrom
ruflin:pipeline-example

Conversation

@ruflin
Copy link
Collaborator

@ruflin ruflin commented Sep 19, 2019

Pipelines are input specific. Currently there is no simple way for the integrations manager to know which pipeline should be reference in an input. This introduces the convention that the pipeline name must be a variable which matches one of the pipeline file names in the package.

On creating the pipeline instance, the integrations manager will change and prefix the name. The above convention makes it possible to convert it in both places. As an example: The package has an ingest pipeline foo.yml or foo.json, in the input it will reference foo. Then the integration manager builds the datasource and calls it bar-foo. It will the replace the input variable with bar-foo.

This also has consequences on elastic/integrations#3. It means the developer building integrations must ensure that no two pipelines have the same name in one package.

To make sure the name in an input matches a pipeline, later on also a validation step should be added.

Pipelines are input specific. Currently there is no simple way for the integrations manager to know which pipeline should be reference in an input. This introduces the convention that the pipeline name must be a variable which matches one of the pipeline file names in the package.

On creating the pipeline instance, the integrations manager will change and prefix the name. The above convention makes it possible to convert it in both places. As an example: The package has an ingest pipeline `foo.yml` or `foo.json`, in the input it will reference `foo`. Then the integration manager builds the datasource and calls it `bar-foo`. It will the replace the input variable with `bar-foo`.

This also has consequences on elastic/integrations#3. It means the developer building integrations must ensure that no two pipelines have the same name in one package.

To make sure the name in an input matches a pipeline, later on also a validation step should be added.
@ruflin ruflin requested review from jfsiii and skh September 19, 2019 06:49
@ruflin
Copy link
Collaborator Author

ruflin commented Sep 19, 2019

@skh @jfsiii Would be good if you could have a look at the above explanations to see if that makes sense from a manager perspective.

@ruflin
Copy link
Collaborator Author

ruflin commented Sep 19, 2019

@jsoriano Pinging you on this one as it's relevant for elastic/integrations#3

@ruflin
Copy link
Collaborator Author

ruflin commented Sep 25, 2019

Merging for now to have the change in as an example. Overall rethinking of inputs will happen in #110

@ruflin ruflin merged commit f843ed3 into elastic:master Sep 25, 2019
@ruflin ruflin deleted the pipeline-example branch September 25, 2019 06:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant