include/logging.h File Reference


Detailed Description

This header is for including and configuring NoBug.

The idea is that configuration and some commonly used flag declarations are to be kept in one central location. Subsystems are free to define and use additional flags for local use. Typically, this header will be included via some of the basic headers like error.hpp, which in turn gets included e.g. by proc/common.hpp

This header can thus be assumed to be effectively global. It should contain only declarations of global relevance, as any change causes the whole project to be rebuilt. All flags defined here are initialised automatically.

We use the 'NOBUG_DECLARATIONS_ONLY' magic to generate declarations and definitions only out of this header.

Logging configuration
By default, logging is configured such as to emit a small number of informative messages on the starting terminal and to report fatal errors. But besides the usual fine-grained tracing messages, we define a small number of distinct thematic Logging Channels providing a consistent high-level view of what is going on with regards to a specific aspect of the application
  • progress documents a high-level overall view of what the application does
  • render focuses on the working of the render engine (without logging each frame)
  • config shows anything of relevance regarding the configured state of App and session
  • memory allows to diagnose a high-level view of memory management
Any log level can be overridden by an environment variable, for example
 NOBUG_LOG='progress:INFO' ./lumiera 

Definition in file logging.h.

#include <nobug.h>

Include dependency graph for logging.h:

Go to the source code of this file.

Defines

#define NOBUG_DECLARE_ONLY   0
#define NOBUG_DECLARE_ONLY   1

Functions

 NOBUG_CPP_DEFINE_FLAG (all)
 the root switch for all logging
 NOBUG_CPP_DEFINE_FLAG_PARENT (gui_event, all)
 caveat joel, you need to implement this
 NOBUG_CPP_DEFINE_FLAG_PARENT (events, all)
 event which drive the application are separately logged to reconstruct what happend/yielded to a problem
 NOBUG_CPP_DEFINE_FLAG_PARENT (asset_mem, proc_mem)
 NOBUG_CPP_DEFINE_FLAG_PARENT (builder_mem, proc_mem)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mobject_mem, proc_mem)
 NOBUG_CPP_DEFINE_FLAG_PARENT (proc_mem, memory)
 memory busines of the proc layer
 NOBUG_CPP_DEFINE_FLAG_PARENT (memory, logging)
 base flag for memory related logging
 NOBUG_CPP_DEFINE_FLAG_PARENT (cond_sync, sync)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mutex_sync, sync)
 NOBUG_CPP_DEFINE_FLAG_PARENT (sync, logging)
 base flag for syncronization logging
 NOBUG_CPP_DEFINE_FLAG_PARENT (test, logging)
 base flag for software testing
 NOBUG_CPP_DEFINE_FLAG_PARENT (config, logging)
 NOBUG_CPP_DEFINE_FLAG_PARENT (render, logging)
 base channel flag to track overall working of the render engine
 NOBUG_CPP_DEFINE_FLAG_PARENT (plugins, progress)
 progress log, external plugins
 NOBUG_CPP_DEFINE_FLAG_PARENT (pluginloader, common)
 progress log, plugin loader
 NOBUG_CPP_DEFINE_FLAG_PARENT (subsystem, common)
 NOBUG_CPP_DEFINE_FLAG_PARENT (guifacade, common)
 NOBUG_CPP_DEFINE_FLAG_PARENT (interfaceregistry, common)
 NOBUG_CPP_DEFINE_FLAG_PARENT (interface, common)
 progress log, interfaces
 NOBUG_CPP_DEFINE_FLAG_PARENT (configtyped, configsys)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configfiles, configsys)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configsys, common)
 progress log, config subsystem
 NOBUG_CPP_DEFINE_FLAG_PARENT (common, progress)
 progress log for the common lib
 NOBUG_CPP_DEFINE_FLAG_PARENT (resourcecollector, library)
 NOBUG_CPP_DEFINE_FLAG_PARENT (library, progress)
 progress log for the support lib
 NOBUG_CPP_DEFINE_FLAG_PARENT (gui, progress)
 progress log for the gui
 NOBUG_CPP_DEFINE_FLAG_PARENT (session, proc)
 progress log for session datastructure
 NOBUG_CPP_DEFINE_FLAG_PARENT (command, proc)
 progress log for proc-layer command dispatch
 NOBUG_CPP_DEFINE_FLAG_PARENT (proc, progress)
 progress log for the proc layer
 NOBUG_CPP_DEFINE_FLAG_PARENT (fileheader, backend)
 NOBUG_CPP_DEFINE_FLAG_PARENT (threadpool, thread)
 NOBUG_CPP_DEFINE_FLAG_PARENT (threads, thread)
 NOBUG_CPP_DEFINE_FLAG_PARENT (thread, backend)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mmap, backend)
 NOBUG_CPP_DEFINE_FLAG_PARENT (file, backend)
 NOBUG_CPP_DEFINE_FLAG_PARENT (backend, progress)
 progress log for the backend
 NOBUG_CPP_DEFINE_FLAG_PARENT (main, progress)
 progress log for the main starter
 NOBUG_CPP_DEFINE_FLAG_PARENT (progress, logging)
 general application progress base
 NOBUG_CPP_DEFINE_FLAG_PARENT (logging, all)
 base of runtime logging always available
 NOBUG_CPP_DEFINE_FLAG_PARENT (plugins_dbg, debugging)
 NOBUG_CPP_DEFINE_FLAG_PARENT (pluginloader_dbg, common_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (interfaceregistry_dbg, interface_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (interface_dbg, common_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configlookup_dbg, config_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configtyped_dbg, config_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configitem_dbg, config_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (configfile_dbg, config_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (config_dbg, common_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (common_dbg, debugging)
 base of debug logging for the common library
 NOBUG_CPP_DEFINE_FLAG_PARENT (cond_dbg, library_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mutex_dbg, library_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (resourcecollector_dbg, library_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (psplay_dbg, library_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mpool_dbg, library_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (library_dbg, debugging)
 base if debug logging for the support library
 NOBUG_CPP_DEFINE_FLAG_PARENT (gui_dbg, debugging)
 base of debug logging for the gui
 NOBUG_CPP_DEFINE_FLAG_PARENT (command_dbg, proc_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (proc_dbg, debugging)
 base of debug logging for the proc layer
 NOBUG_CPP_DEFINE_FLAG_PARENT (fileheader_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (threadpool_dbg, thread_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (threads_dbg, thread_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (thread_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mmapings_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mmapcache_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (mmap_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (filedescriptor_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (filehandlecache_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (filehandle_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (file_dbg, backend_dbg)
 NOBUG_CPP_DEFINE_FLAG_PARENT (backend_dbg, debugging)
 base of debug logging for the backend
 NOBUG_CPP_DEFINE_FLAG_PARENT (main_dbg, debugging)
 debug logging for the main application starter
 NOBUG_CPP_DEFINE_FLAG_PARENT (debugging, all)
 debug logging


Function Documentation

NOBUG_CPP_DEFINE_FLAG ( all   ) 

the root switch for all logging

NOBUG_CPP_DEFINE_FLAG_PARENT ( debugging  ,
all   
)

debug logging

NOBUG_CPP_DEFINE_FLAG_PARENT ( main_dbg  ,
debugging   
)

debug logging for the main application starter

NOBUG_CPP_DEFINE_FLAG_PARENT ( backend_dbg  ,
debugging   
)

base of debug logging for the backend

NOBUG_CPP_DEFINE_FLAG_PARENT ( proc_dbg  ,
debugging   
)

base of debug logging for the proc layer

NOBUG_CPP_DEFINE_FLAG_PARENT ( gui_dbg  ,
debugging   
)

base of debug logging for the gui

NOBUG_CPP_DEFINE_FLAG_PARENT ( library_dbg  ,
debugging   
)

base if debug logging for the support library

NOBUG_CPP_DEFINE_FLAG_PARENT ( common_dbg  ,
debugging   
)

base of debug logging for the common library

NOBUG_CPP_DEFINE_FLAG_PARENT ( logging  ,
all   
)

base of runtime logging always available

NOBUG_CPP_DEFINE_FLAG_PARENT ( progress  ,
logging   
)

general application progress base

NOBUG_CPP_DEFINE_FLAG_PARENT ( main  ,
progress   
)

progress log for the main starter

NOBUG_CPP_DEFINE_FLAG_PARENT ( backend  ,
progress   
)

progress log for the backend

NOBUG_CPP_DEFINE_FLAG_PARENT ( proc  ,
progress   
)

progress log for the proc layer

NOBUG_CPP_DEFINE_FLAG_PARENT ( command  ,
proc   
)

progress log for proc-layer command dispatch

NOBUG_CPP_DEFINE_FLAG_PARENT ( session  ,
proc   
)

progress log for session datastructure

NOBUG_CPP_DEFINE_FLAG_PARENT ( gui  ,
progress   
)

progress log for the gui

NOBUG_CPP_DEFINE_FLAG_PARENT ( library  ,
progress   
)

progress log for the support lib

NOBUG_CPP_DEFINE_FLAG_PARENT ( common  ,
progress   
)

progress log for the common lib

NOBUG_CPP_DEFINE_FLAG_PARENT ( configsys  ,
common   
)

progress log, config subsystem

NOBUG_CPP_DEFINE_FLAG_PARENT ( interface  ,
common   
)

progress log, interfaces

NOBUG_CPP_DEFINE_FLAG_PARENT ( pluginloader  ,
common   
)

progress log, plugin loader

NOBUG_CPP_DEFINE_FLAG_PARENT ( plugins  ,
progress   
)

progress log, external plugins

NOBUG_CPP_DEFINE_FLAG_PARENT ( render  ,
logging   
)

base channel flag to track overall working of the render engine

NOBUG_CPP_DEFINE_FLAG_PARENT ( test  ,
logging   
)

base flag for software testing

NOBUG_CPP_DEFINE_FLAG_PARENT ( sync  ,
logging   
)

base flag for syncronization logging

NOBUG_CPP_DEFINE_FLAG_PARENT ( memory  ,
logging   
)

base flag for memory related logging

NOBUG_CPP_DEFINE_FLAG_PARENT ( proc_mem  ,
memory   
)

memory busines of the proc layer

NOBUG_CPP_DEFINE_FLAG_PARENT ( events  ,
all   
)

event which drive the application are separately logged to reconstruct what happend/yielded to a problem

NOBUG_CPP_DEFINE_FLAG_PARENT ( gui_event  ,
all   
)

caveat joel, you need to implement this


Generated on Sun Aug 1 21:31:06 2010 for Lumiera by  doxygen 1.5.6