6 Commits

Author SHA1 Message Date
Ad Schellevis
0adece8d3e System/Logging - add log search time constraint (valid_from) to limit searches when only a few lines match.
When searching large log files for messages that do not frequently occur, there is a large risk of reading all collected lines before returning the first results.
In most cases recent items are required, in which case going back for days of logs might not make sense.

This commit adds a simple "history" selection which translates into a "valid_from" filter on the log data. When timestamps are not parseable for whatever reason, the filter is ignored.

Only small downside is that we do need to translate timestamp again, when needed we could improve performance a bit by storing the original datetime value in NewBaseLogFormat so we don't have to parse it twice.
2024-08-24 20:55:12 +02:00
Ad Schellevis
6e409a0a2f System: Log Files: Boot - empty log view due to minor regression in c522ecac65 2024-07-03 18:23:26 +02:00
Stephan de Wit
c522ecac65 configd: extend log query mechanism with streaming capability 2024-06-21 12:31:54 +02:00
MaxXor
e21159a973
src: resolve deprecation warnings for sre_constants (#7460)
ref https://github.com/python/cpython/issues/91308
2024-05-16 19:28:50 +02:00
Ad Schellevis
cee33f5393 Firewall log - prevent memory exhaustion using the new streaming functions. closes https://github.com/opnsense/core/issues/6680 2023-11-22 21:56:50 +01:00
Franco Fichtner
fe21864884 health: clean up scripts/systemheath location #5877
Unfortunately this requires relocating the logging plugins to its
proper location which also affects plugins using that location.
2022-11-04 09:45:10 +01:00