This new multi parser type can provide multiple data entries, each
having their own timestamp. The parsing interface is simply extended
so that the new parser returns an array of data elementrs, all in
rrdtool data format. The data is then fed directly to rrdtool via
"rrdtool update" command. New parser also is given the timestamp of
the last update.
As data timestamp is now provided by the parser, there are quite
significant implications on the timeout handling. Previously the
expectation was that each rrd database is updated only once during its
update interval and data fetching happens only once during an update
interval.
This expectation is no longer valid as the parser can return bunch of
data, which is all in past. And the parser would be happy to give even
more data if it was give a chance to do so. Therefore, the actual
"last_update" timestamp is now taken from the latest data entry. And
after each complete update, the job scheduler is notified to do a
re-schedule in order to start a new round of data acquicition in case
there is more data to parse.
The scheduler now needs to be able to wait indefinitely in case all
parsers are still active and there is no information about when a next
event is going to happen. Also a new backoff timestamp is introduced
to prevent the parser from continuously re-staring parsing in case the
data source fails to provide any new data at all.
Signed-off-by: Timo Kokkonen <timo.t.kokkonen@iki.fi>