You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I reported it at the old FasterXML/jackson-datatype-jsr310, and then I found this repo is the current in maintain workspace, then I also checked the corresponding source, which suggests that the reported issue still exists. It is possible that I missed something in this new repo, but just report it again to make sure it is OK.
Notice that, with the default configuration, READ_DATE_TIMESTAMPS_AS_NANOSECONDS is true, it will create a FromDecimalArguments with the passed timestamp value, and which will be passed to the following source:
publicstaticfinalInstantDeserializer<OffsetDateTime> OFFSET_DATE_TIME = newInstantDeserializer<>(
OffsetDateTime.class, DateTimeFormatter.ISO_OFFSET_DATE_TIME,
OffsetDateTime::from,
a -> OffsetDateTime.ofInstant(Instant.ofEpochMilli(a.value), a.zoneId),
a -> OffsetDateTime.ofInstant(Instant.ofEpochSecond(a.integer, a.fraction), a.zoneId),
(d, z) -> d.withOffsetSameInstant(z.getRules().getOffset(d.toLocalDateTime())),
true// yes, replace +0000 with Z
);
to be precision, the following row:
a -> OffsetDateTime.ofInstant(Instant.ofEpochSecond(a.integer, a.fraction), a.zoneId),
which will handle the value as epoch seconds, rather than nano second.
Is there anything that I misunderstand? Or it is actually a bug?
The text was updated successfully, but these errors were encountered:
I reported it at the old FasterXML/jackson-datatype-jsr310, and then I found this repo is the current in maintain workspace, then I also checked the corresponding source, which suggests that the reported issue still exists. It is possible that I missed something in this new repo, but just report it again to make sure it is OK.
the origin issue report:
https://github.com/FasterXML/jackson-datatype-jsr310/issues/96
when InstantDeserializer get a long value for OffsetDateTime, it will entering the following method:
Notice that, with the default configuration, READ_DATE_TIMESTAMPS_AS_NANOSECONDS is true, it will create a FromDecimalArguments with the passed timestamp value, and which will be passed to the following source:
to be precision, the following row:
which will handle the value as epoch seconds, rather than nano second.
Is there anything that I misunderstand? Or it is actually a bug?
The text was updated successfully, but these errors were encountered: