MessagePack v0.9.0 Release Notes
-
👍 This version support reading and writing Timestamp values. Packer and unpacker interfaces added pack/unpackTimestamp methods.
Timestamp value in MessagePack is an extension type value whose code is -1. You can read TimestampValue object with MessgageUnapcker.unpackValue method. If you are using low-level unpack methods (e.g., unpackInt, unpackExtension, etc.), you need to read unpackExtensionHeader first, and if extHeader.isTimestampType() is true, call unpackTimestamp(extHeader).
📄 Timestamp values are represented with java.time.Instant objects. You can extract the unixtime value with Instant.getEpochSecond(), unixtime with milliseconds resolution with Instant.toEpochMilli(), and nano-resolution time with Instant.getNano().
As TimestampValue is just a sub class of ExtensionValue, no change requierd in your code that are traversing MessagePack data with MessageUnpacker.unpackValue method.
⚡️ Dependency updates:
- ⚡️ Update jackson-databind to 2.10.5.1 #559
⚡️ Internal updates: