Avrora.Encoder.extract_schema

You're seeing just the function extract_schema, go back to Avrora.Encoder module for more information.

Specs

extract_schema(binary()) :: {:ok, Avrora.Schema.t()} | {:error, term()}

Extract schema from the binary Avro message.

Examples

...> payload = <<0, 0, 0, 0, 8, 72, 48, 48, 48, 48, 48, 48, 48, 48, 45, 48,
48, 48, 48, 45, 48, 48, 48, 48, 45, 48, 48, 48, 48, 45, 48, 48, 48, 48, 48,
48, 48, 48, 48, 48, 48, 48, 123, 20, 174, 71, 225, 250, 47, 64>>
...> {:ok, schema} = Avrora.Encoder.extract_schema(payload)
...> schema.id
42
...> schema.full_name
"io.confluent.Payment"