You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+11-5Lines changed: 11 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -58,15 +58,21 @@ Below you can find a sample `log4j2.xml` snippet employing `RedisAppender`.
58
58
</Configuration>
59
59
```
60
60
61
-
If you have Sentinel cluster please configure RedisAppender like this:
61
+
One can make `RedisAppender` work against a
62
+
[sentinel](https://redis.io/topics/sentinel) setup using `sentinelNodes` and
63
+
`sentinelMaster` parameters:
64
+
62
65
```xml
63
66
<RedisAppendername="REDIS"
64
67
key="log4j2-messages"
65
68
sentinelNodes="localhost:63791,localhost:63792"
66
69
sentinelMaster="mymaster">
67
70
...
68
71
</RedisAppender>
69
-
```
72
+
```
73
+
74
+
Note that `sentinelNodes` and `sentinelMaster` have priority over `host` and
75
+
`port` parameters.
70
76
71
77
`RedisAppender` is configured with the following parameters:
72
78
@@ -76,8 +82,8 @@ If you have Sentinel cluster please configure RedisAppender like this:
76
82
|`key`| String || Redis queue key |
77
83
|`host`| String |`localhost`| Redis host|
78
84
|`port`| int | 6379 | Redis port |
79
-
|`sentinelNodes`| String |`localhost:63791,localhost:63792`| Redis sentinel nodes as comma-separated list. If specified, `host` and `port` parameters are ignored. |
80
-
|`sentinelMaster`| String |`mymaster`| Redis sentinel master name |
85
+
|`sentinelNodes`| String |`null`| Redis sentinel nodes as comma-separated list, e.g., `host1:port1,host2:port2`. If specified, `host` and `port` parameters are ignored. |
86
+
|`sentinelMaster`| String |`null`| Redis sentinel master name |
81
87
|`password`| String |`null`| Redis password |
82
88
|`connectionTimeoutSeconds`| int | 2 | initial connection timeout in seconds |
83
89
|`socketTimeoutSeconds`| int | 2 | socket timeout in seconds |
0 commit comments