Hello all,
I am wondering what is the easiest way to clone a Schema, then filter
out, or add a property, to some of its fields ?
Basically, I am implementing something similar to avro-sorting,
https://github.com/alexholmes/avro-sorting
, but want to hack the Schema on the fly rather than having to rely on
something like AvroDataHack.
----
class MyBean {
private String foo;
private String bar;
[...]
}
Schema schema = ReflectData.get().getSchema(MyBean.class);
// Here I want to clone schema then filter out bar (add order:ignore
to it)
----
I am mainly interested in supporting top level fields of a record, but
not against a more comprehensive solution.
Thanks,
Clément