# This is an log configuration file example.
# It can be used for a fined grained selection of what should be logged.
# It must respect the format for python log configuration file: 
# https://docs.python.org/3.5/library/logging.config.html#logging-config-fileformat
#
# loggers qualified name of course depends on pydcop. The most common loggers are 
# given as example in this file.

[loggers]
keys=root,dpop,maxsum,mgm2,orchestrator,communication,agent, distucs, clisolve, discovery

[handlers]
keys=handlerout,handlerfile

[formatters]
keys=form01

[logger_root]
level=WARNING
handlers=handlerout


# Loggers for various DCOP algorithms : MGM, MaxSum, DS, DPOP, etc...
[logger_maxsum]
level=WARNING
handlers=handlerout
propagate=0
qualname=maxsum

[logger_dpop]
level=WARNING
handlers=handlerout
propagate=0
qualname=maxsum


[logger_mgm2]
level=WARNING
handlers=handlerout,handlerfile
propagate=0
qualname=mgm2

[logger_clisolve]
level=WARNING
handlers=handlerout,handlerfile
propagate=0
qualname=pydcop.solve


# Logger for replication algorithm
[logger_distucs]
level=INFO
handlers=handlerout,handlerfile
propagate=0
qualname=ucs_replication

[logger_discovery]
level=DEBUG
handlers=handlerout,handlerfile
propagate=0
qualname=pydcop.discovery


# Logger for agents and orchestrator
[logger_orchestrator]
level=INFO
handlers=handlerout,handlerfile
propagate=0
qualname=pydcop.orchestrator

[logger_agent]
level=DEBUG
handlers=handlerout,handlerfile
propagate=0
qualname=pydcop.agent

# Logger for communication: VERY verbose in debug and info level !
[logger_communication]
level=WARNING
handlers=handlerout,handlerfile
propagate=0
qualname=infrastructure.communication

[handler_handlerout]
class=StreamHandler
level=NOTSET
formatter=form01
args=(sys.stdout,)

[handler_handlerfile]
class=FileHandler
level=DEBUG
formatter=form01
args=('run_2reparations_ucs2.log', 'w')

[formatter_form01]
# format=F1 %(asctime)s %(levelname)s %(message)s
format=%(asctime)s.%(msecs)03d - %(name)s - %(levelname)s - %(message)s
datefmt=%H:%M:%S
class=logging.Formatter
