Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add CRC64-AVRO-LE fingerprint type #490

Closed
wants to merge 1 commit into from
Closed

Conversation

kimgr
Copy link
Contributor

@kimgr kimgr commented Jan 20, 2025

The Avro specification details a Single Object Encoding using a header to associate a schema ID with an Avro payload. The ID is defined as the CRC64 fingerprint in little-endian encoding.

The pkg/crc64 module only provides big-endian CRC64, and the CRC64-AVRO fingerprint type is implemented as such. The specification does not detail endianness of the CRC64-AVRO fingerprint itself (only when embedded in an SOE header).

To avoid breaking existing CRC64-AVRO fingerprints, add a new fingerprint type CRC64-AVRO-LE, identical to CRC64-AVRO except little-endian.

Add an additional crc64.SumLittleEndian function to distrurb existing code as little as possible.

Add tests and benchmarks for the Sum functions.

Fixes #489.

The Avro specification details a Single Object Encoding using a header
to associate a schema ID with an Avro payload. The ID is defined as the
CRC64 fingerprint in little-endian encoding.

The pkg/crc64 module only provides big-endian CRC64, and the CRC64-AVRO
fingerprint type is implemented as such. The specification does not
detail endianness of the CRC64-AVRO fingerprint itself (only when
embedded in an SOE header).

To avoid breaking existing CRC64-AVRO fingerprints, add a new
fingerprint type CRC64-AVRO-LE, identical to CRC64-AVRO except
little-endian.

Add an additional crc64.SumLittleEndian function to distrurb existing
code as little as possible.

Add tests and benchmarks for the Sum functions.

Fixes hamba#489.
@kimgr
Copy link
Contributor Author

kimgr commented Jan 20, 2025

See also #491

@kimgr
Copy link
Contributor Author

kimgr commented Jan 23, 2025

Closed, seems like everyone prefers #491.

@kimgr kimgr closed this Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

CRC64 schema fingerprint endianness
1 participant