From b92a017dba61b4b2d11dc2bba468ffe80a69c5a1 Mon Sep 17 00:00:00 2001 From: Gregory Soutade Date: Thu, 23 Jun 2022 21:21:18 +0200 Subject: [PATCH] Update documentation --- docs/index.md | 65 +++++++++++++++++++++++++++++++++++++------------ docs/main.md | 5 ++-- docs/modules.md | 60 ++++++++++++++++++++++++++++++++++----------- 3 files changed, 98 insertions(+), 32 deletions(-) diff --git a/docs/index.md b/docs/index.md index ac461ad..44db964 100644 --- a/docs/index.md +++ b/docs/index.md @@ -11,9 +11,10 @@ Nevertheless, iwla is only focused on HTTP logs. It uses data (robots definition Usage ----- - ./iwla [-c|--clean-output] [-i|--stdin] [-f FILE|--file FILE] [-d LOGLEVEL|--log-level LOGLEVEL] [-r|--reset year/month] [-z|--dont-compress] [-p] [-D|--dry-run] + ./iwla [-c|--config-file file] [-C|--clean-output] [-i|--stdin] [-f FILE|--file FILE] [-d LOGLEVEL|--log-level LOGLEVEL] [-r|--reset year/month] [-z|--dont-compress] [-p] [-D|--dry-run] - -c : Clean output (database and HTML) before starting + -c : Configuration file to use (default conf.py) + -C : Clean output (database and HTML) before starting -i : Read data from stdin instead of conf.analyzed_filename -f : Analyse this log file, multiple files can be specified (comma separated). gz files are acceptedRead data from FILE instead of conf.analyzed_filename -d : Loglevel in ['DEBUG', 'INFO', 'WARNING', 'ERROR', 'CRITICAL'] @@ -121,6 +122,7 @@ Optional configuration values ends with *. * plugins/display/track_users.py * plugins/post_analysis/browsers.py * plugins/post_analysis/feeds.py + * plugins/post_analysis/filter_users.py * plugins/post_analysis/hours_stats.py * plugins/post_analysis/ip_to_geo.py * plugins/post_analysis/iptogeo.py @@ -214,6 +216,7 @@ iwla robot hit_only is_page + keep_requests valid_visitors: month_stats without robot and hit only visitors (if not conf.count_hit_only_visitors) @@ -318,20 +321,8 @@ plugins.display.filter_users None Conf values needed : - filtered_users : list of filters - filtered_ip : list of ip (string) create_filtered_page* - Filter is a list of filter description combined by AND operator - Filter description is a list of 3 elements : - - * Field to match in visits - * Operator '=', '==', '!=', '>', '>=', '<', '<=' for int value - * Operator '=', '==', '!=', 'in', 'match' for str value - * Target value - - For easiest config, you can indicate both 'remote_addr' or 'ip' in field element - Output files : OUTPUT_ROOT/year/month/index.html OUTPUT_ROOT/year/month/filtered_users.html @@ -788,6 +779,48 @@ plugins.post_analysis.feeds None +plugins.post_analysis.filter_users +---------------------------------- + + Post analysis hook + + Filter users with given user conditions + + Plugin requirements : + None + + Conf values needed : + filtered_users : list of filters + filtered_ip : list of ip (string) + create_filtered_page* + + Filter is a list of filter description combined by AND operator + Filter description is a list of 3 elements : + + * Field to match in visits + * Operator '=', '==', '!=', '>', '>=', '<', '<=' for int value + * Operator '=', '==', '!=', 'in', 'match' for str value + * Target value + + For easiest config, you can indicate both 'remote_addr' or 'ip' in field element + + Output files : + None + + Statistics creation : + visits : + remote_addr => + filtered + + Statistics update : + visits : + remote_addr => + keep_requests + + Statistics deletion : + None + + plugins.post_analysis.hours_stats --------------------------------- @@ -1089,8 +1122,7 @@ plugins.pre_analysis.robots None Conf values needed : - page_to_hit_conf* - hit_to_page_conf* + None Output files : None @@ -1102,6 +1134,7 @@ plugins.pre_analysis.robots visits : remote_addr => robot + keep_requests Statistics deletion : None diff --git a/docs/main.md b/docs/main.md index af2d30d..535ab4c 100644 --- a/docs/main.md +++ b/docs/main.md @@ -11,9 +11,10 @@ Nevertheless, iwla is only focused on HTTP logs. It uses data (robots definition Usage ----- - ./iwla [-c|--clean-output] [-i|--stdin] [-f FILE|--file FILE] [-d LOGLEVEL|--log-level LOGLEVEL] [-r|--reset year/month] [-z|--dont-compress] [-p] [-D|--dry-run] + ./iwla [-c|--config-file file] [-C|--clean-output] [-i|--stdin] [-f FILE|--file FILE] [-d LOGLEVEL|--log-level LOGLEVEL] [-r|--reset year/month] [-z|--dont-compress] [-p] [-D|--dry-run] - -c : Clean output (database and HTML) before starting + -c : Configuration file to use (default conf.py) + -C : Clean output (database and HTML) before starting -i : Read data from stdin instead of conf.analyzed_filename -f : Analyse this log file, multiple files can be specified (comma separated). gz files are acceptedRead data from FILE instead of conf.analyzed_filename -d : Loglevel in ['DEBUG', 'INFO', 'WARNING', 'ERROR', 'CRITICAL'] diff --git a/docs/modules.md b/docs/modules.md index 59eab32..a4f7dfe 100644 --- a/docs/modules.md +++ b/docs/modules.md @@ -19,6 +19,7 @@ * plugins/display/track_users.py * plugins/post_analysis/browsers.py * plugins/post_analysis/feeds.py + * plugins/post_analysis/filter_users.py * plugins/post_analysis/hours_stats.py * plugins/post_analysis/ip_to_geo.py * plugins/post_analysis/iptogeo.py @@ -112,6 +113,7 @@ iwla robot hit_only is_page + keep_requests valid_visitors: month_stats without robot and hit only visitors (if not conf.count_hit_only_visitors) @@ -216,20 +218,8 @@ plugins.display.filter_users None Conf values needed : - filtered_users : list of filters - filtered_ip : list of ip (string) create_filtered_page* - Filter is a list of filter description combined by AND operator - Filter description is a list of 3 elements : - - * Field to match in visits - * Operator '=', '==', '!=', '>', '>=', '<', '<=' for int value - * Operator '=', '==', '!=', 'in', 'match' for str value - * Target value - - For easiest config, you can indicate both 'remote_addr' or 'ip' in field element - Output files : OUTPUT_ROOT/year/month/index.html OUTPUT_ROOT/year/month/filtered_users.html @@ -686,6 +676,48 @@ plugins.post_analysis.feeds None +plugins.post_analysis.filter_users +---------------------------------- + + Post analysis hook + + Filter users with given user conditions + + Plugin requirements : + None + + Conf values needed : + filtered_users : list of filters + filtered_ip : list of ip (string) + create_filtered_page* + + Filter is a list of filter description combined by AND operator + Filter description is a list of 3 elements : + + * Field to match in visits + * Operator '=', '==', '!=', '>', '>=', '<', '<=' for int value + * Operator '=', '==', '!=', 'in', 'match' for str value + * Target value + + For easiest config, you can indicate both 'remote_addr' or 'ip' in field element + + Output files : + None + + Statistics creation : + visits : + remote_addr => + filtered + + Statistics update : + visits : + remote_addr => + keep_requests + + Statistics deletion : + None + + plugins.post_analysis.hours_stats --------------------------------- @@ -987,8 +1019,7 @@ plugins.pre_analysis.robots None Conf values needed : - page_to_hit_conf* - hit_to_page_conf* + None Output files : None @@ -1000,6 +1031,7 @@ plugins.pre_analysis.robots visits : remote_addr => robot + keep_requests Statistics deletion : None