Log4j > Loki API

Hi everyone, is anyone out there using the custom appender for log4j to send logs to Loki - https://github.com/tkowalcz/tjahzi/tree/master/log4j2-appender
Its mentioned in the Loki docs Send log data to Loki | Grafana Loki documentation

Using this XML works from a local device to send to Loki but when deployed at a cloud location in Prod we don’t get anything in Loki. Have already doublechecked the VPN tunnel and firewall - nothing blocking traffic there.

Any thoughts?

<Configuration status="INFO" name="cloudhub" packages="[com.mulesoft.ch](http://com.mulesoft.ch/).logging.appender,pl.tkowalcz.tjahzi.log4j2"><dependency>

<groupId>pl.tkowalcz.tjahzi</groupId>
<artifactId>log4j2-appender-nodep</artifactId>
<version>0.9.17</version>
</dependency> <appenders>
<Loki name="LOKI" bufferSizeMegabytes="64">
<host>myhost.mydomain</host>
<port>3100</port>
<logEndpoint>/loki/api/v1/push</logEndpoint>
<useSSL>false</useSSL> <ThresholdFilter level="ALL"/>
<PatternLayout>
<Pattern>%X{tid} [%t] %d{MM-dd HH:mm:ss.SSS} %5p %c{1} - %m%n%exception{full}</Pattern>
</PatternLayout> <Header name="X-Scope-OrgID" value="mulesoft"/>
<Label name="server" value="127.0.0.1"/>

Increase your worker size to at least 0.2 V core

Make sure to set the bufferSizeMegabytes to a desired lower size. See the sample appender:

<Loki name=“Loki” bufferSizeMegabytes=“10” batchWait=“10” host=“${sys:loki.host}” port=“${sys:loki.port}” useSSL=“true” >

<PatternLayout >

</PatternLayout >

<Label name=“app” value=“grafana-loki” />

<Label name=“service” value=“${sys:app.name}” />

</Loki >