# Two distinct elasticsearch outputs in logstash (https,http)

**URL:** <https://discuss.elastic.co/t/two-distinct-elasticsearch-outputs-in-logstash-https-http/300138>\
**Category:** Logstash\
**Tags:** docker\
**Created:** [March 20, 2022, 5:50pm UTC](https://discuss.elastic.co/t/two-distinct-elasticsearch-outputs-in-logstash-https-http/300138 "2022-03-20T17:50:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![INS](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ins/32/92827_2.png) [@INS](https://discuss.elastic.co/u/INS)\
**Post date:** [March 20, 2022, 5:50pm UTC](https://discuss.elastic.co/t/two-distinct-elasticsearch-outputs-in-logstash-https-http/300138/1 "2022-03-20T17:50:28Z")

</div>

Hi  
I'm wondering if I can setup multi-output for the two endpoint (one of this address is corresponding to http and the second one works through https)  
How I can use different Elasticsearch output for https and http? for the same data?

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [March 20, 2022, 10:58pm UTC](https://discuss.elastic.co/t/two-distinct-elasticsearch-outputs-in-logstash-https-http/300138/2 "2022-03-20T22:58:58Z")

</div>

Yes, you can have two Elasticsearch outputs in the output section and by default all the events will get sent to both. There is no problem with one being http and the other https.

---

<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 18, 2022, 6:29am UTC](https://discuss.elastic.co/t/two-distinct-elasticsearch-outputs-in-logstash-https-http/300138/4 "2022-04-18T06:29:06Z")

</div>

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