Skip to content

Configurable schemas auto-registration

Compare
Choose a tag to compare
@Strech Strech released this 08 Sep 21:46
· 84 commits to master since this release
e749040

It's bin a while we have a release. In this one, you will find many good changes.

New configuration option

Starting this version you can have an explicit split between schema reader and schema writer. This means that you don't need to have local files with schemas if you would like to rely only on the schemas already registered in the registry.

config :avrora,
  # ...
  registry_schemas_autoreg: false

If you disable auto registration and have schema registry configured, two major behavior changes will happen:

  1. Local files will be completely ignored for schema resolution
  2. For encoding and decoding, the schema will be retrieved from the registry (see n.1)

For the case when the schema registry is not configured – behavior should remain the same 😉

New Avrora.Codec interface

An Encoder module gets some attention and was refactored. It was split into several submodules which implement the same behavior. It allows code to be reused and well tested separately. But everything comes at a cost, hopefully pros and cons should balance each other.

Happy coding everyone and any feedback is welcome 🤗