This is going to be one of those huge PR's with a bunch of different tasks associated with it. We could probably have split this up into several PRs but there are so many changes that are just us figuring stuff out along the way. We kinda to implement one subcommand to know how to use the CLI library.
This PR adds CLI support and some basic subcommands and options.
It also implements one of the subcommands, simulate fill, and handles the the options: --startat, --duration and --gap.
The first two, startat and duration, are handled by slicing the metrics array by finding the indexes of metrics which match the options, see SliceBetween in metrics.go for specifics.
The last one, gap, is handled by changing how the "real" timestamps are calculated when sending metrics to InfluxDB.
This is going to be one of those huge PR's with a bunch of different tasks associated with it. We could probably have split this up into several PRs but there are so many changes that are just us figuring stuff out along the way. We kinda to implement one subcommand to know how to use the CLI library.
This PR adds CLI support and some basic subcommands and options. It also implements one of the subcommands,
simulate fill
, and handles the the options:--startat
,--duration
and--gap
. The first two,startat
andduration
, are handled by slicing the metrics array by finding the indexes of metrics which match the options, see SliceBetween in metrics.go for specifics. The last one,gap
, is handled by changing how the "real" timestamps are calculated when sending metrics to InfluxDB.