Files
floci/src/main/java
James Netherton a876db87ef fix(cloudwatch): parse decimal epoch timestamps in JSON protocol handler (#1388)
The AWS SDK v2 serialises Instant values via DateUtils.formatUnixTimestampInstant(),
producing decimal epoch-second strings (e.g. "1750000000.123"). The JSON handler
was using parseInstant(node.asText()), which failed for these values: Instant.parse()
rejects them (not ISO-8601) and Long.parseLong() rejects the decimal point.

This caused two silent failures:
- GetMetricStatistics: StartTime/EndTime parsed as null, defaulting the filter to
  0..MAX_VALUE and returning all datapoints regardless of the requested time range
- PutMetricData: MetricDatum.Timestamp parsed as null, causing metrics to be stored
  with the current time instead of the caller-supplied timestamp

Fix by switching to parseInstantNode(JsonNode), the existing helper that calls
node.asLong() for numeric nodes and already handles this correctly for GetMetricData.
2026-06-17 00:33:14 -05:00
..