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

Consider adopting fastutil for deserialization of primitive collections #397

Open
j-tyler opened this issue Oct 7, 2022 · 0 comments
Open

Comments

@j-tyler
Copy link

j-tyler commented Oct 7, 2022

Array and Maps of primitive types are common in Avro schema. Java collections do an acceptable generic job, but type-specific collections such as fastutil can save overhead in multiple ways:

  1. No boxing/unboxing of numbers.
  2. Primitive type-specific collections lower memory overhead of underlying representations.
  3. Which is more pronounced in JVM heaps over 32gb due to 16bit object reference overhead.

fastutil is well respected and widely adopted for performance, so using it for Java representation of Avro data could provide a nice benefit.

@j-tyler j-tyler changed the title Consider adopting fastutil for codegen primitive collections Consider adopting fastutil for deserialization of primitive collections Oct 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant