-
Notifications
You must be signed in to change notification settings - Fork 8
/
log4rs_sample.yml
201 lines (191 loc) · 4.4 KB
/
log4rs_sample.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
refresh_rate: 30 seconds
appenders:
# An appender named "stdout" that writes to stdout
stdout:
kind: console
encoder:
pattern: "{d(%Y-%m-%dT%H:%M:%S%Z)} {h({l}):5} {t} {m}{n}"
filters:
- kind: threshold
level: info
# An appender named "p2pool" that writes to a file with a custom pattern encoder
p2pool:
kind: rolling_file
path: "{{log_dir}}/log/p2pool.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/p2pool.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} [{t}] {l:5} {m} // {f}:{L}{n}"
# An appender named "other" that writes to a file with a custom pattern encoder
other:
kind: rolling_file
path: "{{log_dir}}/log/other.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/other.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
filters:
- kind: threshold
level: info
sync:
kind: rolling_file
path: "{{log_dir}}/log/sync.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/sync.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
filters:
- kind: threshold
level: info
peers:
kind: rolling_file
path: "{{log_dir}}/log/peers.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/peers.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
filters:
- kind: threshold
level: info
p2p:
kind: rolling_file
path: "{{log_dir}}/log/p2p.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/p2p.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
filters:
- kind: threshold
level: info
message_logging:
kind: rolling_file
path: "{{log_dir}}/log/messages.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/messages.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
peer_info:
kind: rolling_file
path: "{{log_dir}}/log/peer_info.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/peer_info.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
new_tip_notify:
kind: rolling_file
path: "{{log_dir}}/log/new_tip_notify.log"
policy:
kind: compound
trigger:
kind: size
limit: 10mb
roller:
kind: fixed_window
base: 1
count: 5
pattern: "{{log_dir}}/log/new_tip_notify.{}.log"
encoder:
pattern: "{d(%Y-%m-%d %H:%M:%S.%f)} {l:5} {m} // {f}:{L}{n}"
# Set the default logging level to "warn" and attach the "stdout" appender to the root
root:
level: info
appenders:
- stdout
- other
loggers:
sync_request:
level: info
appenders:
- sync
additive: false
tari::p2pool:
level: info
appenders:
- p2pool
- stdout
additive: false
tari::p2pool::peer_store:
level: info
appenders:
- p2pool
- stdout
- peers
additive: false
tari::p2pool::topics::peer_info:
level: debug
appenders:
- peer_info
additive: false
tari::p2pool::topics::new_tip_notify:
level: debug
appenders:
- new_tip_notify
additive: false
tari::p2pool::server::p2p:
level: info
appenders:
- p2p
- stdout
additive: false
# For debugging only
# tari::p2pool::message_logging:
# level: debug
# appenders:
# - message_logging
# additive: false