Subject: | parsing of log lines not correct |
Hi all,
I've found that the regular expression that matches searchd log is incomplete.
From the sources of sphinx - searchd.cpp, LogQuery function - you can see that there are 3
more optionals fields in a query log format that are ignored and so the parsing fails.
In particular the optionals fields ignored are multi-query multiplier, performance counters
and query comment. If any of these information is logged, the parsing of the line will be not
done correctly.
Personally I found this problem while parsing my query log file where is present the multi-
query multiplier factor.
The documentation on sphinx site is deceptive because these optionals fields are not
documented in query log format section. The correct query log format is as follows:
[query-date] query-time multiquery-factor [match-mode/filters-count/sort-mode total-
matches (offset,limit) @groupby-attr] [index-name] [performances-counters] [query-
comment] query
I've already patched the module and I'm going to send a mail to the author with my proposal.
Some system information:Perl 5.10, Sphinx::Log::Parser 0.02, OS: Linux & Mac OS X.
Thank you for the attention,
Paolo Lunazzi