in analytics/src/main/java/com/amazonaws/services/timestream/TimestreamSink.java [104:118]
private Collection<Record> createRecords(Collection<TimestreamPoint> points) {
return points.stream()
.map(point -> new Record()
.withDimensions(point.getDimensions().entrySet().stream()
.map(entry -> new Dimension()
.withName(entry.getKey())
.withValue(entry.getValue()))
.collect(Collectors.toList()))
.withMeasureName(point.getMeasureName())
.withMeasureValueType(point.getMeasureValueType())
.withMeasureValue(point.getMeasureValue())
.withTimeUnit(point.getTimeUnit())
.withTime(String.valueOf(point.getTime())))
.collect(Collectors.toList());
}