Statistics
| Branch: | Tag: | Revision:

root / snf-webproject / conf / 10-snf-webproject-logging.conf @ d63a86d6

History | View | Annotate | Download (2.5 kB)

1 6a8d05b4 Christos Stavrakakis
# # -*- coding: utf-8 -*-
2 6a8d05b4 Christos Stavrakakis
# #
3 6a8d05b4 Christos Stavrakakis
# # Logging configuration
4 6a8d05b4 Christos Stavrakakis
# ##################################
5 6d20b7f3 Vangelis Koukis
#
6 6d20b7f3 Vangelis Koukis
#
7 6a8d05b4 Christos Stavrakakis
# FORMATTERS = {
8 6a8d05b4 Christos Stavrakakis
#         'simple': {
9 6a8d05b4 Christos Stavrakakis
#             'format': '%(asctime)s [%(levelname)s] %(message)s'
10 6a8d05b4 Christos Stavrakakis
#         },
11 6a8d05b4 Christos Stavrakakis
#         'verbose': {
12 6a8d05b4 Christos Stavrakakis
#             'format': '%(asctime)s [%(process)d] %(name)s %(module)s [%(levelname)s] %(message)s'
13 6a8d05b4 Christos Stavrakakis
#         },
14 6a8d05b4 Christos Stavrakakis
#         'django': {
15 6a8d05b4 Christos Stavrakakis
#             'format': '[%(asctime)s] %(levelname)s %(message)s',
16 6a8d05b4 Christos Stavrakakis
#             'datefmt': '%d/%b/%Y %H:%M:%S'
17 6a8d05b4 Christos Stavrakakis
#         },
18 6a8d05b4 Christos Stavrakakis
# }
19 6d20b7f3 Vangelis Koukis
#
20 6d20b7f3 Vangelis Koukis
#
21 6a8d05b4 Christos Stavrakakis
# LOGGING_SETUP = {
22 6a8d05b4 Christos Stavrakakis
#     'version': 1,
23 6a8d05b4 Christos Stavrakakis
#     'disable_existing_loggers': True,
24 6d20b7f3 Vangelis Koukis
#
25 6a8d05b4 Christos Stavrakakis
#     'formatters':  FORMATTERS,
26 6a8d05b4 Christos Stavrakakis
#     'handlers': {
27 6a8d05b4 Christos Stavrakakis
#         'null': {
28 6a8d05b4 Christos Stavrakakis
#             'class': 'logging.NullHandler',
29 6a8d05b4 Christos Stavrakakis
#         },
30 6a8d05b4 Christos Stavrakakis
#         'console': {
31 6a8d05b4 Christos Stavrakakis
#             'class': 'logging.StreamHandler',
32 6a8d05b4 Christos Stavrakakis
#             'formatter': 'verbose'
33 6a8d05b4 Christos Stavrakakis
#         },
34 6a8d05b4 Christos Stavrakakis
#         'syslog': {
35 6a8d05b4 Christos Stavrakakis
#             'class': 'logging.handlers.SysLogHandler',
36 6a8d05b4 Christos Stavrakakis
#             'address': '/dev/log',
37 6a8d05b4 Christos Stavrakakis
# #            'address': ('localhost', 514),
38 6a8d05b4 Christos Stavrakakis
#             'facility': 'daemon',
39 6a8d05b4 Christos Stavrakakis
#             'formatter': 'verbose',
40 6a8d05b4 Christos Stavrakakis
#             'level': 'INFO',
41 6a8d05b4 Christos Stavrakakis
#         },
42 6a8d05b4 Christos Stavrakakis
#     },
43 6d20b7f3 Vangelis Koukis
#
44 6a8d05b4 Christos Stavrakakis
#     'loggers': {
45 6a8d05b4 Christos Stavrakakis
#         '': {
46 6a8d05b4 Christos Stavrakakis
#             'handlers': ['console'],
47 6a8d05b4 Christos Stavrakakis
#             'level': 'INFO'
48 6a8d05b4 Christos Stavrakakis
#         },
49 6a8d05b4 Christos Stavrakakis
#         'synnefo': {
50 6a8d05b4 Christos Stavrakakis
#             'handlers': ['console'],
51 6a8d05b4 Christos Stavrakakis
#             'level': 'INFO',
52 6a8d05b4 Christos Stavrakakis
#             'propagate': 0
53 6a8d05b4 Christos Stavrakakis
#         },
54 6a8d05b4 Christos Stavrakakis
#     }
55 6a8d05b4 Christos Stavrakakis
# }
56 6d20b7f3 Vangelis Koukis
#
57 6a8d05b4 Christos Stavrakakis
# LOGGING_SETUP['loggers']['synnefo.admin'] = {'level': 'INFO', 'propagate': 1}
58 6a8d05b4 Christos Stavrakakis
# LOGGING_SETUP['loggers']['synnefo.api'] = {'level': 'INFO', 'propagate': 1}
59 6a8d05b4 Christos Stavrakakis
# LOGGING_SETUP['loggers']['synnefo.db'] = {'level': 'INFO', 'propagate': 1}
60 6a8d05b4 Christos Stavrakakis
# LOGGING_SETUP['loggers']['synnefo.logic'] = {'level': 'INFO', 'propagate': 1}
61 6d20b7f3 Vangelis Koukis
#
62 6a8d05b4 Christos Stavrakakis
# # To set logging level for plankton to DEBUG just uncomment the follow line:
63 6a8d05b4 Christos Stavrakakis
# # LOGGING_SETUP['loggers']['synnefo.plankton'] = {'level': 'INFO', 'propagate': 1}
64 6d20b7f3 Vangelis Koukis
#
65 6a8d05b4 Christos Stavrakakis
# SNF_MANAGE_LOGGING_SETUP = {
66 6a8d05b4 Christos Stavrakakis
#     'version': 1,
67 6a8d05b4 Christos Stavrakakis
#     'disable_existing_loggers': True,
68 6d20b7f3 Vangelis Koukis
#
69 6a8d05b4 Christos Stavrakakis
#     'formatters': FORMATTERS,
70 6a8d05b4 Christos Stavrakakis
#
71 6a8d05b4 Christos Stavrakakis
#     'handlers': {
72 6a8d05b4 Christos Stavrakakis
#         'console': {
73 6a8d05b4 Christos Stavrakakis
#             'class': 'logging.StreamHandler',
74 6a8d05b4 Christos Stavrakakis
#             'formatter': 'verbose'
75 6a8d05b4 Christos Stavrakakis
#         },
76 6a8d05b4 Christos Stavrakakis
#     },
77 6a8d05b4 Christos Stavrakakis
#
78 6a8d05b4 Christos Stavrakakis
#     'loggers': {
79 6a8d05b4 Christos Stavrakakis
#         '': {
80 6a8d05b4 Christos Stavrakakis
#                 'handlers': ['console'],
81 6a8d05b4 Christos Stavrakakis
#                 'level': 'WARNING'
82 6a8d05b4 Christos Stavrakakis
#             },
83 6a8d05b4 Christos Stavrakakis
#     }
84 6a8d05b4 Christos Stavrakakis
# }
85 6a8d05b4 Christos Stavrakakis
#
86 6a8d05b4 Christos Stavrakakis
# SNF_MANAGE_LOGGING_SETUP['loggers']['synnefo'] = {'handlers': ['console'],
87 6a8d05b4 Christos Stavrakakis
#                                                   'level': 'WARNING',
88 6a8d05b4 Christos Stavrakakis
#                                                   'propagate': 0}