Stephen Morse
05/15/2025, 2:53 PMNonEmptyList
(using NonEmptyListSerializer
) between Arrow v1 and v2? My company (Cash App/Block) has some data serialized with the NonEmptyListSerializer
of Arrow v1, but we need to upgrade to Arrow v2. Is it possible to define a serializer that can deserialize both the v1 and v2 binary formats? 🤔Stephen Morse
05/15/2025, 2:54 PMwe had to break binary compatibility in several places to implement improvements, such as inNonEmptyList
Youssef Shoaib [MOD]
05/15/2025, 3:08 PMList
, serialize it again, deserialize in 2.0, and finally convert it to NonEmptyList
and serializephldavies
05/15/2025, 3:52 PMwe had to break binary compatibility in several places to implement improvements, such as inthis is referencing the binary compatibility of the arrow-core library itself, not the kotlinx-serialization serialized content (assuming that's what you mean by serialized) The incompatibility would arise should you try and execute a binary/jar compiled against arrow v1 with arrow v2 on the classpathNonEmptyList
phldavies
05/15/2025, 3:55 PMNonEmptyListSerializer
is a simple wrapper around a delegated ListSerializer
with the additional conversion to NonEmptyList
using .toNonEmptyListOrNull() ?: throw SerializationException("expected non-empty list")
when deserializingUlrich Schuster
05/15/2025, 4:10 PMNonEmptyList
for API parameters or similar data structures where Spring attempts to create proxies.phldavies
05/15/2025, 4:18 PMAlejandro Serrano.Mena
05/15/2025, 7:45 PMAlejandro Serrano.Mena
05/15/2025, 7:46 PMNonEmptyList
has changed
• on the other hand, serializing in v1 and deserializing in v2 should work fine (or even the other way around), since both turn into the same thing