Avro schemas is defined with JSON. This facilitates implementation in languages that already has JSON libraries.

Source: Internet
Author: User

https://avro.apache.org/docs/current/

Introduction

Apache Avro? is a data serialization system.

Avro provides:

    • Rich data structures.
    • A Compact, fast, binary data format.
    • A container file, to store persistent data.
    • Remote procedure Call (RPC).
    • Simple integration with dynamic languages. Code generation is not required to read or write data files and to the use or implement RPC protocols. Code generation as an optional optimization, only worth implementing for statically typed languages.

Schemas

Avro relies on schemas. When Avro data was read, the schema used when writing it was always present. This permits all datum to is written with no per-value overheads, making serialization both fast and small. This also facilitates use with dynamic, scripting languages, since data, together with its schema, is fully self-describin G.

When Avro data was stored in a file, the IT schema is stored with it and so the files may be processed later by any program. If The program reading the data expects a different schema this can be easily resolved, since both schemas is present.

When Avro are used in RPC, the client and server Exchange schemas in the connection handshake. (This can is optimized so, for most calls, no schemas is actually transmitted.) Since both client and server both has the other's full schema, correspondence between same named Fields, missing fields, Extra fields, etc. can all be easily resolved.

Avro schemas is defined with JSON. This facilitates implementation in languages that already has JSON libraries.

Comparison with other systems

Avro provides functionality similar to systems such as Thrift, Protocol buffers, etc. Avro differs from these systems in the following fundamental aspects.

    • Dynamic Typing: Avro does not require that code is generated. Data is all accompanied by a schema, this permits full processing of the that data without code generation, static datatypes , etc. This facilitates construction of generic data-processing systems and languages.
    • untagged Data: Since The schema is present if data is read, considerably less type information need be encoded With data, resulting in smaller serialization size.
    • No manually-assigned Field IDs: When a schema changes, both the old and new schema is always present when proces Sing data, so differences is resolved symbolically, using field names.

Avro schemas is defined with JSON. This facilitates implementation in languages that already has JSON libraries.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.