diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-12-22 01:32:18 +0300 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-12-22 01:32:18 +0300 |
commit | e413f4ee9cd298baab701df31ab4c1cb91c7c4b6 (patch) | |
tree | 46858bef680c8a09b6d1d58a5ca7e3a8cec4e62d /src/cfg_file.y | |
parent | a079dac866ac4e166a8d6e40f978af74e8398583 (diff) | |
download | rspamd-e413f4ee9cd298baab701df31ab4c1cb91c7c4b6.tar.gz rspamd-e413f4ee9cd298baab701df31ab4c1cb91c7c4b6.zip |
* Introduce new logging system:
- independent and customizeable buffering
- line buffering
- errors handling support
- custom (ip based) debug
- append function name automaticaly (based on __FUNCTION__)
- add some logic to logs system
Diffstat (limited to 'src/cfg_file.y')
-rw-r--r-- | src/cfg_file.y | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/cfg_file.y b/src/cfg_file.y index 91c40a734..8c7f232b1 100644 --- a/src/cfg_file.y +++ b/src/cfg_file.y @@ -60,6 +60,7 @@ struct rspamd_view *cur_view = NULL; %token VIEW IP FROM SYMBOLS CLIENT_IP %token AUTOLEARN MIN_MARK MAX_MARK MAXFILES MAXCORE %token SETTINGS USER_SETTINGS DOMAIN_SETTINGS SYMBOL PATH SKIP_CHECK GROW_FACTOR +%token LOG_BUFFER DEBUG_IP %type <string> STRING %type <string> VARIABLE @@ -583,6 +584,8 @@ loggingcmd: | loggingfacility | loggingfile | loggingurls + | loggingbuffer + | loggingdebugip ; loggingtype: @@ -678,6 +681,20 @@ loggingurls: } ; +loggingbuffer: + LOG_BUFFER EQSIGN NUMBER + | LOG_BUFFER EQSIGN SIZELIMIT { + cfg->log_buf_size = $3; + cfg->log_buffered = TRUE; + } + ; + +loggingdebugip: + DEBUG_IP EQSIGN QUOTEDSTRING { + cfg->debug_ip_map = $3; + } + ; + classifier: CLASSIFIER OBRACE classifierbody EBRACE { if (cur_classifier == NULL || cur_classifier->classifier == NULL) { |