All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
messages_sbnd.fcl
Go to the documentation of this file.
1 #
2 # File: messages_sbnd.fcl
3 # Purpose: presets for art message logging
4 # Author: Gianluca Petrillo
5 # Date: June 1st, 2016
6 # Version: 1.0
7 #
8 # Provided presets:
9 # - sbnd_message_services: kind of "standard"
10 # - sbnd_message_services_prod: non-interactive jobs (like in production)
11 # - sbnd_message_services_prod_debug: non-interactive jobs with debugging
12 # - sbnd_message_services_interactive: interactive jobs
13 # - sbnd_message_services_interactive_debug: interactive jobs with debugging
14 #
15 # Reminder: to limit a number of messages in a specific category,
16 # add in a destination a configuration for that category:
17 #
18 # categories: {
19 #
20 # # suppress all the messages in "UselessMessage" category
21 # UselessMessage: { limit: 0 }
22 #
23 # # reduce the messages from "AnnoyingMessage" category;
24 # # they will still appear now and then
25 # AnnoyingMessage: { limit: 5 timespan: 10 }
26 #
27 # # this means no limit
28 # default: {}
29 #
30 # }
31 #
32 #
33 # Usage:
34 #
35 # services.message: @local::sbnd_message_services
36 #
37 #
38 # Changes:
39 # 20160601 (petrillo@fnal.gov) [v1.0]
40 # content moved from old services_sbnd.fcl;
41 # tuned the various presets, added a couple
42 #
43 
44 
45 BEGIN_PROLOG
46 
47 #
48 # standard SBND message destinations
49 #
50 message_debugfile_sbnd: {
51  #
52  # message destination: all debug messages to a file
53  #
54  type: "file"
55  filename: "debug.log"
56  append: false
57  threshold: "DEBUG"
58  categories: {
59  default: {}
60  }
61 } # message_debugfile_sbnd
62 
63 
64 message_infofile_sbnd: {
65  #
66  # message destination: all debug messages to a file
67  #
68  type: "file"
69  filename: "messages.log"
70  append: false
71  threshold: "INFO"
72  categories: {
73  default: {}
74  }
75 } # message_infofile_sbnd
76 
77 
78 message_errorfile_sbnd: {
79  #
80  # message destination: all error messages to "errors.log" file
81  #
82  type: "file"
83  filename: "errors.log"
84  append: false
85  threshold: "ERROR"
86  categories: {
87  default: {}
88  }
89 } # message_errorfile_sbnd
90 
91 
92 message_stdout_warning_sbnd: {
93  #
94  # message destination: all warning messages to standard output
95  #
96  type: "cout"
97  threshold: "WARNING"
98  categories:{
99  default: {}
100  GeometryBadInputPoint: { limit: 5 timespan: 1000}
101  }
102 } # message_stdout_warning_sbnd
103 
104 
105 message_stderr_sbnd: {
106  #
107  # message destination: all error messages to standard error
108  #
109  type: "cerr"
110  threshold: "ERROR"
111  categories:{
112  default: {}
113  }
114 } # message_stderr_sbnd
115 
116 
117 
118 #
119 # sbnd_message_services
120 # ------------------------
121 #
122 # Enables debug messages. Errors saved in a file.
123 #
124 # - standard output with only WARNING and worse
125 # - "errors.log" collecting error messages (also included in standard output)
126 # - "debug.log" with DEBUG (that is, every message) for all modules;
127 # in non-debug qualifier builds, LOG_DEBUG and LOG_TRACE are disabled and
128 # their messages are never produced (that is, won't be in "debug.log" either).
129 #
130 # No special stream for errors.
131 #
132 sbnd_message_services:
133 {
134  destinations: {
135  LogStandardOut: @local::message_stdout_warning_sbnd
136  LogInfoFile: @local::message_infofile_sbnd
137  LogErrorFile: @local::message_errorfile_sbnd
138  }
139 
140 } # sbnd_message_services
141 
142 
143 #
144 # sbnd_message_services_prod_debug
145 # -----------------------------------
146 #
147 # Enables debug messages.
148 #
149 # - standard error with only ERROR and worse
150 # - standard output with only WARNING and worse (will also repeat the error
151 # messages, that will appear in error messages being printed twice if the
152 # standard output and error are directed to the same file or to the console)
153 # - "debug.log" with DEBUG (that is, every message) for all modules;
154 # in non-debug qualifier builds, LOG_DEBUG and LOG_TRACE are disabled and
155 # their messages are never produced (that is, won't be in "debug.log" either).
156 #
157 sbnd_message_services_prod_debug:
158 {
159  debugModules: ["*"]
160 
161  destinations: {
162  LogDebugFile: @local::message_debugfile_sbnd
163  LogStandardOut: @local::message_stdout_warning_sbnd
164  LogStandardError: @local::message_stderr_sbnd
165  }
166 } # sbnd_message_services_prod_debug
167 
168 
169 sbnd_message_services_prod_debug.destinations.LogDebugFile.categories:{
170  default: { }
171  GeometryBadInputPoint: { limit: 5 timespan: 1000}
172 }
173 
174 
175 #
176 # sbnd_message_services_prod
177 # -----------------------------
178 #
179 # - standard error with only ERROR and worse
180 # - standard output with only WARNING and worse (will also repeat the error
181 # messages, that will appear in error messages being printed twice if the
182 # standard output and error are directed to the same file or to the console)
183 #
184 #
185 sbnd_message_services_prod:
186 {
187  destinations: {
188  LogStandardOut: @local::message_stdout_warning_sbnd
189  LogStandardError: @local::message_stderr_sbnd
190  }
191 }
192 
193 
194 #
195 # sbnd_message_services_interactive
196 # ------------------------------------
197 #
198 # - standard output with only INFO and worse
199 # - "errors.log" collecting warning and error messages (also included in
200 # standard output)
201 #
202 # No special stream for errors.
203 #
204 #
205 sbnd_message_services_interactive:
206 {
207  destinations: {
208  LogStandardOut: @local::message_stdout_warning_sbnd
209  LogErrorFile: @local::message_errorfile_sbnd
210  }
211 }
212 sbnd_message_services_interactive.destinations.LogStandardOut.threshold: "INFO"
213 sbnd_message_services_interactive.destinations.LogErrorFile.threshold: "WARNING"
214 
215 
216 #
217 # sbnd_message_services_interactive_debug
218 # ------------------------------------------
219 #
220 # Enables debug messages.
221 #
222 # - standard output with only INFO and worse
223 # - "errors.log" collecting warning and error messages (also included in
224 # standard output)
225 # - "debug.log" with DEBUG (that is, every message) for all modules;
226 # in non-debug qualifier builds, LOG_DEBUG and LOG_TRACE are disabled and
227 # their messages are never produced (that is, won't be in "debug.log" either).
228 #
229 # No special stream for errors.
230 #
231 #
232 sbnd_message_services_interactive_debug: {
233  debugModules: ["*"]
234  @table::sbnd_message_services_interactive
235 }
236 sbnd_message_services_interactive_debug.destinations.LogDebugFile: @local::message_debugfile_sbnd
237 
238 
239 END_PROLOG
BEGIN_PROLOG could also be dds filename