Skip to content

Commit e115829

Browse files
committed
Update docs, dependencies
1 parent 9ca4270 commit e115829

File tree

1 file changed

+17
-16
lines changed

1 file changed

+17
-16
lines changed

README.md

+17-16
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ The default `com.github.exabrial.logback.JmsAppender` will work almost-out-of-th
2424
</dependency>
2525
```
2626

27-
If you're logging to graylog I suggest you also use the GELF encoder from this project: https://github.com/Moocar/logback-gelf
27+
If you're logging to Graylog I suggest you also use a GELF encoder:
2828

2929
```
3030
<dependency>
31-
<groupId>me.moocar</groupId>
31+
<groupId>de.siegmar</groupId>
3232
<artifactId>logback-gelf</artifactId>
33-
<version>0.3</version>
33+
<version>3.0.0</version>
3434
<scope>runtime</scope>
3535
</dependency>
3636
```
@@ -48,7 +48,7 @@ If you're logging to graylog I suggest you also use the GELF encoder from this p
4848

4949
### Example Configuration
5050

51-
This configuration uses the GELF encoder mentioned earlier (since I send my logging events to Graylog), but any Logback encoder could be used.
51+
This configuration uses the GELF encoder mentioned earlier (since I send my logging events to Graylog), but any Logback encoder could be used. Note you should replace `${project.artifactId}` below:
5252

5353
```
5454
<?xml version="1.0" encoding="UTF-8"?>
@@ -58,19 +58,20 @@ This configuration uses the GELF encoder mentioned earlier (since I send my logg
5858
<appender
5959
name="gelf-jms"
6060
class="com.github.exabrial.logback.JmsAppender">
61-
<queueName>com.example.logback</queueName>
62-
<encoder class="ch.qos.logback.core.encoder.LayoutWrappingEncoder">
63-
<layout class="me.moocar.logbackgelf.GelfLayout">
64-
<useLoggerName>true</useLoggerName>
65-
<useThreadName>true</useThreadName>
66-
<includeFullMDC>true</includeFullMDC>
67-
<staticField class="me.moocar.logbackgelf.Field">
68-
<key>_app</key>
69-
<value>your-app-name</value>
70-
</staticField>
71-
</layout>
72-
</encoder>
7361
<async>true</async>
62+
<queueName>com.emoneyusa.logback</queueName>
63+
<encoder class="de.siegmar.logbackgelf.GelfEncoder">
64+
<includeCallerData>true</includeCallerData>
65+
<includeRootCauseData>true</includeRootCauseData>
66+
<includeLevelName>true</includeLevelName>
67+
<shortPatternLayout class="ch.qos.logback.classic.PatternLayout">
68+
<pattern>%.100ex{short}%.100m</pattern>
69+
</shortPatternLayout>
70+
<fullPatternLayout class="ch.qos.logback.classic.PatternLayout">
71+
<pattern>%msg</pattern>
72+
</fullPatternLayout>
73+
<staticField>app:${project.artifactId}</staticField>
74+
</encoder>
7475
</appender>
7576
<root level="info">
7677
<appender-ref ref="gelf-jms" />

0 commit comments

Comments
 (0)