9 Commits

Author SHA1 Message Date
21b68afa03 testbench: Adjusted timing for test imfile-logrotate-async.sh
In some cases, the logrotate is not fast enough rotating the
logfile after sighub has been send to inputfilegen process. It appears
to happen more often on github CI machines, when it happens,
inputfilegen reopens the NOT yet rotated file and keeps writing
into it. However most messages written until the next sighub are lost
after the logfile finally is rotated.

In order to avoid this, I have added an extra sleep between file
CLOSE and OPEN after sighub with a default of 5ms which appears to work
very well. This should give logrotate enough time to perform the
actuzal rotate.

Also added another parameter to inputfilegen to keep the process
open after finish. Which helps syncing with the testcases.

closes: https://github.com/rsyslog/rsyslog/issues/5000
2022-10-14 11:15:45 +02:00
Rainer Gerhards
6be9a266ea
testbench: add testcase for frequent imfile input file change
PoC test, yet incomplete

This patch not only contains the new test but also supporting
changes to testbench tooling.

see also: https://github.com/rsyslog/rsyslog/issues/4797
2022-08-04 12:54:07 +02:00
Rainer Gerhards
2d89f3d2cc testbench: add imfile tests for files > 2GB
see also https://github.com/rsyslog/rsyslog/issues/3249
2018-11-11 13:54:40 +01:00
Rainer Gerhards
11273d8738 testbench: fix portability issues under AIX 2018-08-31 09:06:46 -05:00
f19ead2551 imfile: Added test for dynamic renamed files (wildcard)
Added check for IN_MOVED_TO in in_handleDirEvent. Statefilename and
event cookie are saved in IN_MOVE_FROM event in a linkedlist now,
so the statefile can be renamed to a new name in IN_MOVED_TO event.

Closes https://github.com/rsyslog/rsyslog/issues/1417
2017-06-23 11:21:28 +02:00
pwithopf
4b7227cb1c testbench: rewrite inputfilegen with new functionality 2016-11-04 15:02:30 +01:00
Rainer Gerhards
99aecbdb85 testbench: add test for object persisting
see also https://github.com/rsyslog/rsyslog/issues/1239
2016-11-03 10:43:56 +01:00
Rainer Gerhards
ffdc33e3f1 imfile: added $InputFileMaxLinesAtOnce directive 2011-05-24 10:09:43 +02:00
Rainer Gerhards
4195f9cb08 added new test for imfile to testbench 2011-03-11 10:58:07 +01:00