pjfanning opened a new pull request, #654:
URL: https://github.com/apache/pekko-connectors-kafka/pull/654

   ### Motivation
   The `Check Code Style` job, which runs `checkCodeStyle; 
mimaReportBinaryIssues`, fails with `java.lang.OutOfMemoryError: Java heap 
space`. sbt runs with its default 1g heap and spends most of the job in GC 
before dying:
   
   ```
   [warn] In the last 10 seconds, 24.282 (253.1%) were spent in GC.
          [Heap: 0.00GB free of 1.00GB, max 1.00GB] Consider increasing the JVM 
heap using `-Xmx` ...
   java.lang.OutOfMemoryError: Java heap space
   [error] [launcher] error during sbt launcher: java.lang.OutOfMemoryError: 
Java heap space
   ```
   
   The unscoped `mimaReportBinaryIssues` loads current and previous classfiles 
for every module in one JVM, so it is the peak consumer.
   
   This is not specific to any one PR — `main` has failed the same way on every 
run since #652 ([run 
34266703572](https://github.com/apache/pekko-connectors-kafka/actions/runs/34266703572)),
 and it is what is currently failing #653 ([run 
34545658900](https://github.com/apache/pekko-connectors-kafka/actions/runs/34545658900)).
   
   ### Modification
   Set `JAVA_OPTS: "-Xmx4g"` in the workflow-level `env` block of the CI 
workflow, so every job in it gets a 4g heap.
   
   4g matches what this repository already uses for its other heavy sbt jobs 
(`link-validator.yml`, `publish-1.0-docs.yml`, `publish-1.1-docs.yml`, 
`publish-1.2-docs.yml`, `publish-2.0-docs.yml`, `publish-nightly.yml`) and is 
well inside the memory available on the GitHub-hosted runners.
   
   Deliberately confined to the CI workflow rather than `.sbtopts`, so local 
sbt runs keep whatever heap the developer has configured.
   
   ### Result
   The binary-compatibility check completes instead of exhausting the heap, and 
the `Check / Binary Compatibility` job can pass again.
   
   ### Tests
   - Not run - CI configuration only; the change is verified by the CI run on 
this PR, which is the job that was failing.
   
   ### References
   Refs #653 - that PR is blocked by this same pre-existing failure
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to