Skip to content

increase java heap memory during tests #47

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

brahyt-sf
Copy link
Contributor

@brahyt-sf brahyt-sf commented Jun 10, 2025

There is currently a test that has been flaky during the build workflow in github. It will fail with the underlying reason being wiremock running out of heap memory:

java.lang.OutOfMemoryError: Java heap space

This test will typically pass when you re-run this specific job on its own. The current fix is to increase the macos job runner to macos-14-large and increase heap memory for the Java environment. Tests running in these jobs have yet to fail while running simultaneously.

The purpose of this specific test is to generate a large test dataset that would be returned by salesforce and to handle that payload accordingly.

@brahyt-sf brahyt-sf requested a review from a team as a code owner June 10, 2025 21:05
Copy link

@dhagberg-sf dhagberg-sf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems kinda huge - must be storing a large number of requests/responses in wiremock possibly without clearing results after each test? Oh, but this sets --no-request-journal so it shouldn't be preserving requests/responses.

Anyway, it's just there to be a mock server for tests - so if this works and de-flakes some flakiness, ship it.

@brahyt-sf
Copy link
Contributor Author

Seems kinda huge - must be storing a large number of requests/responses in wiremock possibly without clearing results after each test? Oh, but this sets --no-request-journal so it shouldn't be preserving requests/responses.

Anyway, it's just there to be a mock server for tests - so if this works and de-flakes some flakiness, ship it.

@dhagberg-sf
There is a specific test in the bulk actions thats generating a huge payload here

function createLargeDataset(bulkApi: BulkApi) {

this is the one thats causing the failure, but it appears to be generating data thats similar to how SF can send those resources, so I figured that volume is important to test.

@dhagberg-sf
Copy link

Yah, that would do it. 🚢 .

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 this pull request may close these issues.

3 participants