# Best Way to Combine chain two output plugins

**URL:** <https://discuss.elastic.co/t/best-way-to-combine-chain-two-output-plugins/135428>\
**Category:** Logstash\
**Created:** [June 11, 2018, 8:13pm UTC](https://discuss.elastic.co/t/best-way-to-combine-chain-two-output-plugins/135428 "2018-06-11T20:13:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![adrianz](https://avatars.discourse-cdn.com/v4/letter/a/ecb155/32.png) [@adrianz](https://discuss.elastic.co/u/adrianz)\
**Post date:** [June 11, 2018, 8:13pm UTC](https://discuss.elastic.co/t/best-way-to-combine-chain-two-output-plugins/135428/1 "2018-06-11T20:13:52Z")

</div>

Hello, I have device data currently stored in ElasticSearch, what I need to do is to export the data using Logstash (I'm using the elasticsearch input plugin) do some formatting ETL (extract days into seperate fields) and then output the results into a csv file.

Finally I need to send that csv file to either an S3 bucket, or directly by email. My question is: Is it possible to chain output plugins through Logstash, or is there a work around to this?

---

<div class="post-metadata">

**Author:** ![jakelandis](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jakelandis/32/36163_2.png) [@jakelandis](https://discuss.elastic.co/u/jakelandis)\
**Post date:** [June 13, 2018, 10:36pm UTC](https://discuss.elastic.co/t/best-way-to-combine-chain-two-output-plugins/135428/2 "2018-06-13T22:36:22Z")

</div>

> Is it possible to chain output plugins through Logstash, or is there a work around to this?

In addition to supporting multiple outputs in the same pipeline , you can send data from Logstash to Logstash [Logstash-to-Logstash communication | Logstash Reference [8.11] | Elastic](https://www.elastic.co/guide/en/logstash/current/ls-to-ls.html) , and just released (beta) you can chain sending events from pipeline to pipeline: [Pipeline-to-Pipeline Communication (Beta) | Logstash Reference [6.3] | Elastic](https://www.elastic.co/guide/en/logstash/6.3/pipeline-to-pipeline.html)

However, pushing a whole csv file (or any whole file) to different destinations isn't Logstash's sweet spot , rather smaller individual events (like log lines) is more the typical use case.

---

<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:** [July 11, 2018, 10:36pm UTC](https://discuss.elastic.co/t/best-way-to-combine-chain-two-output-plugins/135428/3 "2018-07-11T22:36:25Z")

</div>

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