Skip to content

Docker image from build-pack Gradle get trouble with volume mount AWS EFS! #189

Answered by dmikusa
kenwiths asked this question in Q&A
Discussion options

You must be logged in to vote

Ok, so the buildpack has a helper that runs before your app starts which dynamically adjusts the memory configuration of the JVM based on the memory available to your container. To do this, it needs to know how many class files are in your app so it can size the metaspace.

To do this, it walks the app directory and counts up the class files. This should generally be fast, where you don't even notice it, but you're binding in remote storage which probably has tons of files and making tons of files, and that is going to be noticeable.

There are two things you can do about this now:

  1. Mount your files somewhere else. Don't put them under /workspace & point your application to the new location.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@kenwiths
Comment options

@dmikusa
Comment options

Answer selected by kenwiths
@kenwiths
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants