MADARA
3.1.8
|
Go to the source code of this file.
Namespaces | |
madara | |
Copyright (c) 2015 Carnegie Mellon University. | |
madara::utility | |
Provides utility functions and classes for common tasks and needs. | |
Macros | |
#define | DLINFO ACE_TEXT("(%P|%t) [%M] - %T - ") |
#define | MADARA_DEBUG(L, X) |
#define | MADARA_DISABLE_TRACE() do {} while (0) |
#define | MADARA_ENABLE_TRACE() do {} while (0) |
#define | MADARA_ERROR(L, X) |
#define | MADARA_ERROR_BREAK(L, X) { MADARA_ERROR (L, X); break; } |
#define | MADARA_ERROR_RETURN(L, X, Y) |
#define | MADARA_LOG_DETAILED_TRACE 10 |
#define | MADARA_LOG_EMERGENCY 0 |
Used for errors that cause the fatal shutdown of any portion of the infrastructure. More... | |
#define | MADARA_LOG_ERROR 3 |
Used to log detailed error information at the point of failure. More... | |
#define | MADARA_LOG_EVENT_TRACE 7 |
Used to trace significant actions within major/minor events. More... | |
#define | MADARA_LOG_MAJOR_DEBUG_INFO 8 |
Used to display important configuration information that impacts major MADARA events. More... | |
#define | MADARA_LOG_MAJOR_EVENT 5 |
Used to indicate that a ``significant'' MADARA event has completed. More... | |
#define | MADARA_LOG_MINOR_EVENT 6 |
Used to inficate a ``minor'' MADARA event has completed. More... | |
#define | MADARA_LOG_NONFATAL_ERROR 2 |
Used for non-fatal deployment errors that do not cause deployment failure. More... | |
#define | MADARA_LOG_TERMINAL_ERROR 1 |
Used for MADARA errors at the point the error exits the process in question, or when a decision is made to cause the MADARA suite to fail. More... | |
#define | MADARA_LOG_TRACE 9 |
The following two statements are used to closely trace the execution of MADARA code. More... | |
#define | MADARA_LOG_WARNING 4 |
used to indicate that a questionable situation that doesn't cause deployment failure, but can cause undefined conditions. More... | |
#define | MADARA_NTRACE 1 |
#define | MADARA_TRACE(X) do {} while (0) |
Enumerations | |
enum | madara::utility::LogLevels { madara::utility::LOG_EMERGENCY = 0, madara::utility::LOG_TERMINAL_ERROR = 1, madara::utility::LOG_NONFATAL_ERROR = 2, madara::utility::LOG_ERROR = 3, madara::utility::LOG_WARNING = 4, madara::utility::LOG_MAJOR_EVENT = 5, madara::utility::LOG_MINOR_EVENT = 6, madara::utility::LOG_EVENT_TRACE = 7, madara::utility::LOG_MAJOR_DEBUG_INFO = 8, madara::utility::LOG_MINOR_DEBUG_INFO = 9, madara::utility::LOG_DETAILED_TRACE = 10 } |
Logging levels available for MADARA library. More... | |
Functions | |
int | madara::utility::get_log_level (void) |
Gets the log level. More... | |
void | madara::utility::log (int level, const char *message) |
Logs a simple string message. More... | |
void | madara::utility::set_log_level (int level) |
Sets the log level. More... | |
Variables | |
ACE_Proper_Import_Flag int | MADARA_debug_level |
Macros used for logging in MADARA, based on the DAnCE Log Macros maintained by Will Otte wotte. @dre .vand erbi lt.ed u
Note that though we include MADARA_Logger_export for future expansion possibilities, we are simply including the LogMacros.h and LogMacros.cpp files into each project that might need these. Otherwise, KATS users would have to explicitly include Madara.dll or Madara.lib and Kats.dll or Kats.lib instead of just Kats.dll or Kats.lib.
Definition in file LogMacros.h.
#define DLINFO ACE_TEXT("(%P|%t) [%M] - %T - ") |
Definition at line 27 of file LogMacros.h.
#define MADARA_DEBUG | ( | L, | |
X | |||
) |
Definition at line 137 of file LogMacros.h.
#define MADARA_DISABLE_TRACE | ( | ) | do {} while (0) |
Definition at line 76 of file LogMacros.h.
#define MADARA_ENABLE_TRACE | ( | ) | do {} while (0) |
Definition at line 75 of file LogMacros.h.
#define MADARA_ERROR | ( | L, | |
X | |||
) |
Definition at line 114 of file LogMacros.h.
#define MADARA_ERROR_BREAK | ( | L, | |
X | |||
) | { MADARA_ERROR (L, X); break; } |
Definition at line 175 of file LogMacros.h.
#define MADARA_ERROR_RETURN | ( | L, | |
X, | |||
Y | |||
) |
Definition at line 162 of file LogMacros.h.
#define MADARA_LOG_DETAILED_TRACE 10 |
Definition at line 65 of file LogMacros.h.
#define MADARA_LOG_EMERGENCY 0 |
Used for errors that cause the fatal shutdown of any portion of the infrastructure.
Definition at line 36 of file LogMacros.h.
#define MADARA_LOG_ERROR 3 |
Used to log detailed error information at the point of failure.
Definition at line 45 of file LogMacros.h.
#define MADARA_LOG_EVENT_TRACE 7 |
Used to trace significant actions within major/minor events.
This will usually include starts for major/minor events.
Definition at line 55 of file LogMacros.h.
#define MADARA_LOG_MAJOR_DEBUG_INFO 8 |
Used to display important configuration information that impacts major MADARA events.
Definition at line 58 of file LogMacros.h.
#define MADARA_LOG_MAJOR_EVENT 5 |
Used to indicate that a ``significant'' MADARA event has completed.
Definition at line 50 of file LogMacros.h.
#define MADARA_LOG_MINOR_EVENT 6 |
Used to inficate a ``minor'' MADARA event has completed.
Definition at line 52 of file LogMacros.h.
#define MADARA_LOG_NONFATAL_ERROR 2 |
Used for non-fatal deployment errors that do not cause deployment failure.
Definition at line 43 of file LogMacros.h.
#define MADARA_LOG_TERMINAL_ERROR 1 |
Used for MADARA errors at the point the error exits the process in question, or when a decision is made to cause the MADARA suite to fail.
Definition at line 40 of file LogMacros.h.
#define MADARA_LOG_TRACE 9 |
The following two statements are used to closely trace the execution of MADARA code.
If in doubt, a message should go into these categories. The difference between a TRACE and a DETAILED_TRACE will be largely a judgement call. These messages should be emitted using MADARA_LOG_TRACE (X, Y).
Definition at line 64 of file LogMacros.h.
#define MADARA_LOG_WARNING 4 |
used to indicate that a questionable situation that doesn't cause deployment failure, but can cause undefined conditions.
Definition at line 48 of file LogMacros.h.
#define MADARA_NTRACE 1 |
Definition at line 69 of file LogMacros.h.
#define MADARA_TRACE | ( | X | ) | do {} while (0) |
Definition at line 74 of file LogMacros.h.
ACE_Proper_Import_Flag int MADARA_debug_level |
Definition at line 5 of file LogMacros.cpp.