# Logstash muitiple pipeline to pipeline configue

**URL:** <https://discuss.elastic.co/t/logstash-muitiple-pipeline-to-pipeline-configue/225777>\
**Category:** Logstash\
**Created:** [March 31, 2020, 3:24am UTC](https://discuss.elastic.co/t/logstash-muitiple-pipeline-to-pipeline-configue/225777 "2020-03-31T03:24:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![judragon\_dark](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/judragon_dark/32/64378_2.png) [@judragon\_dark](https://discuss.elastic.co/u/judragon_dark)\
**Post date:** [March 31, 2020, 3:24am UTC](https://discuss.elastic.co/t/logstash-muitiple-pipeline-to-pipeline-configue/225777/1 "2020-03-31T03:24:04Z")

</div>

I'd like to do a multi-pipeline.

```
- pipeline.id: beats-server

input { beats { port => 5044 } }
output {  
    if [type] == log1 {
      pipeline { send_to => log1 }
    } else if [type] == log2 {
      pipeline { send_to => log2}
    } 
}

- pipeline.id: log1-processing

input { 
     pipeline { address => log1} }
  output {
    elasticsearch { .... }
  }

 - pipeline.id: log2-processing
input { 
     pipeline { address => log2} }
  output {
    elasticsearch { .... }
  }

```

but Setting up is very difficult when there are many pipelines to deal with.  
Can I select a dynamic pipe line with the field that I received from the filebeat?

For example,  
If you send fields from the file bits, I want to do it in simple code as shown below.

```
- pipeline.id: beats-server

input { beats { port => 5044 } }
output {  
      pipeline { send_to => [fields][type] }
}

```

**But the this code doesn't work.**  
**Can dynamically load a pipeline using variables?**

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [March 31, 2020, 5:22am UTC](https://discuss.elastic.co/t/logstash-muitiple-pipeline-to-pipeline-configue/225777/2 "2020-03-31T05:22:49Z")

</div>

No, you can not name pipelines dynamically. They are created at startup before any events are processed and must exist. Basib pipeline IDs on event data could lead to you sending data to pipelines that do not exist, which would be bad.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 28, 2020, 5:29am UTC](https://discuss.elastic.co/t/logstash-muitiple-pipeline-to-pipeline-configue/225777/3 "2020-04-28T05:29:19Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
