messageService.fcl
Go to the documentation of this file.
1 #
2 # Standard configurations for the message service.
3 #
4 # Usage - in a fcl configuration file:
5 #
6 # 1 - Place the following near the start, among the PROLOGs:
7 # #include "fcl/messageService.fcl"
8 #
9 # 2 - Choose the appropriate style of logging, and in the services section of
10 # your fcl file, place one of these four lines:
11 # message : @local::mf_production
12 # message : @local::mf_batch
13 # message : @local::mf_interactive
14 # message : @local::mf_debugging
15 #
16 # 3 - Customizations starting from these standard configurations are
17 # straightforward to make; see customizingMessageFacilityFcl.txt
18 # for simple examples.
19 
20 #include "standardMessageDestinations.fcl"
21 
22 BEGIN_PROLOG
23 
24 # Four standardized (but customizable) styles of logging
25 # ------------------------------------------------------
26 
27 # production -- intended for routine running on a farm or grid, with very
28 # minimal logging (only real ERROR messages).
29 mf_production :
30 {
31  destinations :
32  {
33  log: @local::mf_error # a destination which will react only to
34  # messages of ERROR severity (that is,
35  # messages issued via LogError,
36  # LogProblem, or LogImportant).
37  statistics : { stats: @local::mf_errorStats }
38  }
39 }
40 
41 # This one is similar to mf_production, but it does not create files.
42 # Error messages go to cerr instead. Also there is no statistics.
43 mf_errorsOnly :
44 {
45  destinations : {
46  log: {
47  type: cerr
48  threshold: ERROR
49  }
50  }
51 
52  statistics : { stats: @local::mf_null }
53 }
54 
55 
56 # batch -- intended for near-production monitored running, with info messages
57 # ignored, but with WARNING and ERROR messages output to the log.
58 mf_batch :
59 {
60  destinations :
61  {
62  log: @local::mf_warning # a destination which will react only to
63  # messages of ERROR or WARNING severity
64  # (WARNING severity is LogWarning or
65  # LogPrint).
66  statistics : { stats: @local::mf_warningStats }
67  }
68 }
69 
70 # interactive -- intended for developers running a job, sending the output
71 # of all normal messages to cout.
72 mf_interactive :
73 {
74  destinations :
75  {
76  log: @local::mf_coutInfo # a destination which will react to
77  # messages of ERROR or WARNING or
78  # INFO severity, but not DEBUG severity # LogPrint).
79  # (INFO severity is LogInfo or
80  # LogVerbatim).
81  statistics : { stats: @local::mf_coutInfoStats }
82  }
83 }
84 
85 # debugging -- intended for debugging one or more modules; every message
86 # including those issued via LogDebug will be routed to debug.log.
87 mf_debugging :
88 {
89  debugModules : ["*"] # This "*" will result in LogDebug from all modules
90  # appearing in the log.
91  # Replace this with a list of individual module names
92  # if you only want output from some specific modules.
93  suppressDebug : [ ] # If debugModules remains "*", you can suppress
94  # one or more specific modules by replacing this
95  # list with a list of the modules to be suppressed.
96  destinations :
97  {
98  log: @local::mf_debug # a destination which will react to all
99  # messages, even those issued by
100  # LogDebug or LogTrace.
101  statistics : { stats: @local::mf_debugStats }
102  }
103 }
104 
105 END_PROLOG