synchronized
for what's essentially a concurrent map and a couple of rest calls that need to be cached
[Foo, Bar, Baz]
I can use [null, Foo]
as a reader schema and decode as Option[Foo]
. It really annoys me that Avro doesn't allow that.
vulcan-generic
and I see that the schema getting generated for my sealed trait
has changed. The change is in the order of records. This also affects the references of nested records. Is there a way to control this or prevent that change?
LocalDate
produces weird results where LocalDate.toEpochDay
returns a value greater than the max int (due to internal use of Long.toInt
), obviously its a fairly unlikely scenario in the real world, but just thought I'd mention it!
@bplommer after switching to 1.7.0 I get "Error decoding Option: Error decoding union: Missing alternative array in union" in derived codecs when I decode
GenericData.Record
. But it happens ONLY after ser/de via GenericDatumWriter/GenericDatumReader
Which change might have broken the codec?
@catostrophe eek, thanks for the heads up - would you mind opening a GitHub issue?
Sure
GenericData
, which we wrongly assumed was only used for named types (record, enum, fixed)
bytes: Array[Byte]
// Can I do?
Codec.decode(bytes)
case class FooBar(foo: String, bar: String)
implicit val foobarCodec: Codec[FooBar] =
Codec.record[FooBar](
name = "foo",
namespace = "foo.bar"
) { field =>
(
field("foo", _.foo),
field("bar", _.bar)
).mapN(FooBar)
}