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

AvroGenerateSpecific can generate a schema$ val with length beyond JVM constant limit #167

Closed
natefitzgerald opened this issue Apr 28, 2023 · 2 comments

Comments

@natefitzgerald
Copy link
Contributor

natefitzgerald commented Apr 28, 2023

My organization has a bad habit of using really big Avro schemas. What we found happens is that when AvroGenerateSpecific is used to generate specific records, the val that is added to the companion class ends up beyond the ~65k character length limit for compile-time constant strings, the length of which is encoded as a u2 unsigned int, see here . I can't link the schema here but it's about 100k characters.

(avro_schemas/compile:compileIncremental) java.lang.IllegalArgumentException: Maximum String literal length exceeded

I have a somewhat janky solution that I'm planning to PR to this repo but just in case I don't get around to it this is an issue.

@julianpeeters
Copy link
Owner

Ok great, thank you for the report

@julianpeeters
Copy link
Owner

#182

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

Successfully merging a pull request may close this issue.

2 participants