Skip to content

Commit 9e96ec3

Browse files
wip
1 parent e6f38cc commit 9e96ec3

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/main/java/com/influxdb/v3/client/internal/InfluxDBClientImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ public Stream<Object[]> query(@Nonnull final String query,
221221
} else if ("timestamp".equals(valueType)
222222
|| Objects.equals(schema.getName(), "time")) {
223223
var timestamp = fieldVectors.get(i).getObject(rowNumber);
224-
BigInteger time = NanosecondConverter.getTimestampNanoSecond(timestamp, schema);
224+
BigInteger time = NanosecondConverter.getTimestampNano(timestamp, schema);
225225
row.add(time);
226226
} else {
227227
Object value = fieldVectors.get(i).getObject(rowNumber);

src/main/java/com/influxdb/v3/client/internal/NanosecondConverter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public static BigInteger convert(final Instant instant, final WritePrecision pre
119119
return FROM_NANOS.get(precision).apply(nanos);
120120
}
121121

122-
public static BigInteger getTimestampNanoSecond(@Nonnull final Object value, @Nonnull final Field schema) {
122+
public static BigInteger getTimestampNano(@Nonnull final Object value, @Nonnull final Field schema) {
123123
BigInteger result = null;
124124

125125
if (value instanceof Long) {

src/test/java/com/influxdb/v3/client/internal/NanosecondConverterTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ void testGetTimestampNanosecond() {
2020
new ArrowType.Timestamp(TimeUnit.SECOND, "UTC"),
2121
null);
2222
Field timeFieldSecond = new Field("time", timeTypeSecond, null);
23-
timestampNanoSecond = NanosecondConverter.getTimestampNanoSecond(123_456L, timeFieldSecond);
23+
timestampNanoSecond = NanosecondConverter.getTimestampNano(123_456L, timeFieldSecond);
2424
Assertions.assertEquals(
2525
BigInteger.valueOf(123_456L)
2626
.multiply(BigInteger.valueOf(1_000_000_000)), timestampNanoSecond
@@ -31,7 +31,7 @@ void testGetTimestampNanosecond() {
3131
new ArrowType.Timestamp(TimeUnit.MILLISECOND, "UTC"),
3232
null);
3333
Field timeFieldMilliSecond = new Field("time", timeTypeMilliSecond, null);
34-
timestampNanoSecond = NanosecondConverter.getTimestampNanoSecond(123_456L, timeFieldMilliSecond);
34+
timestampNanoSecond = NanosecondConverter.getTimestampNano(123_456L, timeFieldMilliSecond);
3535
Assertions.assertEquals(
3636
BigInteger.valueOf(123_456L)
3737
.multiply(BigInteger.valueOf(1_000_000)), timestampNanoSecond
@@ -42,7 +42,7 @@ void testGetTimestampNanosecond() {
4242
new ArrowType.Timestamp(TimeUnit.MICROSECOND, "UTC"),
4343
null);
4444
Field timeFieldMicroSecond = new Field("time", timeTypeMicroSecond, null);
45-
timestampNanoSecond = NanosecondConverter.getTimestampNanoSecond(123_456L, timeFieldMicroSecond);
45+
timestampNanoSecond = NanosecondConverter.getTimestampNano(123_456L, timeFieldMicroSecond);
4646
Assertions.assertEquals(
4747
BigInteger.valueOf(123_456L)
4848
.multiply(BigInteger.valueOf(1_000)), timestampNanoSecond
@@ -53,7 +53,7 @@ void testGetTimestampNanosecond() {
5353
new ArrowType.Timestamp(TimeUnit.NANOSECOND, "UTC"),
5454
null);
5555
Field timeFieldNanoSecond = new Field("time", timeTypeNanoSecond, null);
56-
timestampNanoSecond = NanosecondConverter.getTimestampNanoSecond(123_456L, timeFieldNanoSecond);
56+
timestampNanoSecond = NanosecondConverter.getTimestampNano(123_456L, timeFieldNanoSecond);
5757
Assertions.assertEquals(BigInteger.valueOf(123_456L), timestampNanoSecond
5858
);
5959
}

0 commit comments

Comments
 (0)