Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The IO.read method reads the entire JAR file into RAM. In our environment the jar file is roughly 900MB. This was causing Out of Memory exceptions on our machines.
This proposed change will leverage the remote_file resource and the source attribute. The file is still read from the local cache directory. The file is buffered much more effectively when taking this approach.
I also propose updating the action to only create the file if it is missing.
This change reduced the memory consumption of this resource by more than an order of magnitude. This change also reduced the execution duration for this resource by roughly 10 seconds in our environment.
Please let me know if you have any questions.