ebyhr opened a new pull request, #14359:
URL: https://github.com/apache/iceberg/pull/14359
Iceberg throws exceptions if JSON contains default values on timestamp nanos:
```
Caused by: java.lang.ArithmeticException: long overflow
at java.base/java.lang.Math.multiplyExact(Math.java:1035)
at
org.apache.iceberg.util.DateTimeUtil.microsToNanos(DateTimeUtil.java:101)
at
org.apache.iceberg.expressions.Literals$TimestampLiteral.to(Literals.java:447)
at
org.apache.iceberg.expressions.Literals$LongLiteral.to(Literals.java:306)
at
org.apache.iceberg.types.Types$NestedField.castDefault(Types.java:890)
at org.apache.iceberg.types.Types$NestedField.<init>(Types.java:882)
at
org.apache.iceberg.types.Types$NestedField$Builder.build(Types.java:850)
at org.apache.iceberg.SchemaParser.structFromJson(SchemaParser.java:242)
at org.apache.iceberg.SchemaParser.typeFromJson(SchemaParser.java:186)
at org.apache.iceberg.SchemaParser.fromJson(SchemaParser.java:277)
at org.apache.iceberg.util.JsonUtil.parse(JsonUtil.java:104)
at
org.apache.iceberg.SchemaParser.lambda$fromJson$1(SchemaParser.java:296)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.lambda$doComputeIfAbsent$14(BoundedLocalCache.java:2704)
at
java.base/java.util.concurrent.ConcurrentHashMap.compute(ConcurrentHashMap.java:1932)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.doComputeIfAbsent(BoundedLocalCache.java:2702)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.computeIfAbsent(BoundedLocalCache.java:2684)
at
com.github.benmanes.caffeine.cache.LocalCache.computeIfAbsent(LocalCache.java:112)
at
com.github.benmanes.caffeine.cache.LocalManualCache.get(LocalManualCache.java:63)
at org.apache.iceberg.SchemaParser.fromJson(SchemaParser.java:296)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]