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

[BUG][JAVA] OutOfMemoryError Required array length 2147483638 + 2317306 is too large #20482

Open
4 of 6 tasks
c2technology opened this issue Jan 15, 2025 · 0 comments
Open
4 of 6 tasks

Comments

@c2technology
Copy link

Bug Report Checklist

  • Have you provided a full/minimal spec to reproduce the issue?
  • Have you validated the input using an OpenAPI validator (example)?
  • Have you tested with the latest master to confirm the issue still exists?
  • Have you searched for related issues/PRs?
  • What's the actual output vs expected output?
  • [Optional] Sponsorship to speed up the bug fix or feature request (example)
Description

When building a csharp api client with this command generates the error when building the client
npm exec @openapitools/openapi-generator-cli generate -- -g csharp --skip-operation-example -i "swagger.json" -o "/openapi/csharp"
Building clients for Java, Python, and PHP all work without issue.
I would expect the same for csharp

openapi-generator version

10.8.2

OpenAPI declaration file content or url

the swagger file is over 14MB and has 479491 lines. It's generated from source code using Swashbuckle

Generation Details
export JAVA_TOOL_OPTIONS="-Xmx30g"
export DOTNET_SYSTEM_RUNTIME_GCALLOWVERYLARGEOBJECTS=true
npm install @openapitools/openapi-generator-cli -g
npm exec @openapitools/openapi-generator-cli generate -- -g csharp --skip-operation-example -i "swagger.json" -o "/openapi/csharp"
Related issues/PRs

There are a lot of heap issues. I've increased java to 30GB but to no avail. Other client types are build just fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant