# \[ANN\] Log4j2 Elasticsearch appender

**URL:** https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732
**Category:** Elasticsearch
**Created:** [July 18, 2014, 8:08am UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732 "2014-07-18T08:08:07Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)
#### Post date: [July 18, 2014, 8:08am UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/1 "2014-07-18T08:08:07Z")

</div>

Hi,

I released a Log4j2 Elasticsearch appender

> **[jprante/log4j2-elasticsearch](https://github.com/jprante/log4j2-elasticsearch)**
>
> log4j2-elasticsearch - Log4j2 Elasticsearch appender

in the hope it is useful.

Best,

Jörg

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoEc3sHzFu8qD-gQzWsYQ2QFKAG%2BddJdqbSQh%2B0XD%2BSg9g%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoEc3sHzFu8qD-gQzWsYQ2QFKAG%2BddJdqbSQh%2B0XD%2BSg9g%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

### Author: ![brian\_yoder](https://avatars.discourse-cdn.com/v4/letter/b/f1d935/32.png) [@brian\_yoder](https://discuss.elastic.co/u/brian_yoder)
#### Post date: [July 18, 2014, 11:52pm UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/2 "2014-07-18T23:52:41Z")

</div>

Awesome! I had been wondering to myself about this for a while.

Brian

On Friday, July 18, 2014 4:08:14 AM UTC-4, Jörg Prante wrote:

> Hi,
> 
> I released a Log4j2 Elasticsearch appender
> 
> [GitHub - jprante/log4j2-elasticsearch: Log4j2 Elasticsearch appender](https://github.com/jprante/log4j2-elasticsearch)
> 
> in the hope it is useful.
> 
> Best,
> 
> Jörg

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/cff91677-fe6d-48af-85df-dcd09880c44d%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/cff91677-fe6d-48af-85df-dcd09880c44d%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

### Author: ![seralf](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/seralf/32/44805_2.png) [@seralf](https://discuss.elastic.co/u/seralf)
#### Post date: [July 19, 2014, 3:59pm UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/3 "2014-07-19T15:59:05Z")

</div>

I'll try it as soon as I can!  
thanks,  
Alfredo  
🙂

Il giorno venerdì 18 luglio 2014 10:08:14 UTC+2, Jörg Prante ha scritto:

> Hi,
> 
> I released a Log4j2 Elasticsearch appender
> 
> [GitHub - jprante/log4j2-elasticsearch: Log4j2 Elasticsearch appender](https://github.com/jprante/log4j2-elasticsearch)
> 
> in the hope it is useful.
> 
> Best,
> 
> Jörg

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

### Author: ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)
#### Post date: [July 21, 2014, 7:14pm UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/4 "2014-07-21T19:14:06Z")

</div>

I was indexing events into Elasticsearch via the standard SocketAppender  
into Logstash, but I stopped doing so since the SocketAppender was not  
releasing threads. Great to see a direct approach, but I like to use  
Logstash in the middle as a buffer in order to batch events.

--  
Ivan

On Sat, Jul 19, 2014 at 8:59 AM, Alfredo Serafini [seralf@gmail.com](mailto:seralf@gmail.com) wrote:

> I'll try it as soon as I can!  
> thanks,  
> Alfredo  
> 🙂
> 
> Il giorno venerdì 18 luglio 2014 10:08:14 UTC+2, Jörg Prante ha scritto:
> 
> > Hi,
> > 
> > I released a Log4j2 Elasticsearch appender
> > 
> > [GitHub - jprante/log4j2-elasticsearch: Log4j2 Elasticsearch appender](https://github.com/jprante/log4j2-elasticsearch)
> > 
> > in the hope it is useful.
> > 
> > Best,
> > 
> > Jörg
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com)  
> [https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .
> 
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9\_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

### Author: ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)
#### Post date: [July 21, 2014, 7:47pm UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/5 "2014-07-21T19:47:26Z")

</div>

The Log4j appender is batching events because it is using bulk indexing. If  
you are worried, you can set the bulk action size to an extreme high value  
and increase heap to some GB only for buffering log messages, together with  
a reasonable flush interval.

Jörg

On Mon, Jul 21, 2014 at 9:14 PM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:

> I was indexing events into Elasticsearch via the standard SocketAppender  
> into Logstash, but I stopped doing so since the SocketAppender was not  
> releasing threads. Great to see a direct approach, but I like to use  
> Logstash in the middle as a buffer in order to batch events.
> 
> --  
> Ivan
> 
> On Sat, Jul 19, 2014 at 8:59 AM, Alfredo Serafini [seralf@gmail.com](mailto:seralf@gmail.com)  
> wrote:
> 
> > I'll try it as soon as I can!  
> > thanks,  
> > Alfredo  
> > 🙂
> > 
> > Il giorno venerdì 18 luglio 2014 10:08:14 UTC+2, Jörg Prante ha scritto:
> > 
> > > Hi,
> > > 
> > > I released a Log4j2 Elasticsearch appender
> > > 
> > > [GitHub - jprante/log4j2-elasticsearch: Log4j2 Elasticsearch appender](https://github.com/jprante/log4j2-elasticsearch)
> > > 
> > > in the hope it is useful.
> > > 
> > > Best,
> > > 
> > > Jörg
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups  
> > "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an  
> > email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com)  
> > [https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/dce481d9-ac3e-4fd0-aaba-3a4c69d07d34%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > .
> > 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9\_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com)  
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9\_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCppMVB-9_0btCXtPTo67c%2BMFziYDff0qwiptj4kn-hyw%40mail.gmail.com?utm_medium=email&utm_source=footer)  
> .
> 
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoGim0o0LVVFRoLAM2DOHgS-4wM%2BariaLrF3aBg6Vjs2Nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoGim0o0LVVFRoLAM2DOHgS-4wM%2BariaLrF3aBg6Vjs2Nw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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 6, 2017, 1:14am UTC](https://discuss.elastic.co/t/ann-log4j2-elasticsearch-appender/18732/6 "2017-07-06T01:14:26Z")

</div>


