Precision error when specifying time in RFC3339 format vs. UNIX milliseconds
Describe the bug
Certain times seem to trigger a 1ms error if specified in RFC3339 format instead of UNIX milliseconds. This can have consequences such as missing a point if the end parameter is specified in RFC3339 and a point at that timestamp does in fact exist.
To Reproduce
node -e 'console.log(new Date(time=1582301269433).toISOString())' # 2020-02-21T16:07:49.433Z
# create a point
curl http://localhost:8428/api/v1/import/prometheus -d 'series1{label="foo"} 10 1582301269433'
export VMQURL=http://localhost:8428/api/v1/query
# misses the point
curl -s $VMQURL -d 'query=count_over_time(series1[1ms])' -d 'time=2020-02-21T16:07:49.433Z'
# 1ms later, does return the point
curl -s $VMQURL -d 'query=count_over_time(series1[1ms])' -d 'time=2020-02-21T16:07:49.434Z'
Version
victoria-metrics-20240130-205929-tags-v1.97.0-0-gfcc8b14f8
Logs
No response
Screenshots
No response
Used command-line flags
-retentionPeriod=100y -search.latencyOffset=1s
Additional information
No response
#5814
FYI, the fix for this issue has been included in v1.93.13 LTS release.
FYI, the fix for this issue has been included in v1.97.3 LTS release.
The fix for this issue has been included in v1.99.0 release. Closing the issue as fixed.