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
Creating cached artifact hangs on InetAddress.getLocalHost() #11122
Comments
We did make some changes to how the origin metadata is put together in 5.6, calling That said, the problem can be reproduced when only a single task is being packages, i.e. there are no concurrent calls to |
This is the root cause apparently: https://stackoverflow.com/questions/33289695/inetaddress-getlocalhost-slow-to-run-30-seconds |
My best theory right now is that we already had this problem with Gradle 5.5 and earlier. The difference that brought the problem up with 5.6 is that we removed the The workaround in the PR #11134 is to run |
The problem that resolving It seems like the change in Are you saying that the workaround doesn't help any more with macOS Mojave? |
The workaround works as always. However, it is not trivial to notice that you need the workaround. Indeed, it seems that many has been suffering from this problem unknowingly. In some environments the We can fix this in a way that the user doesn't need to learn about and then fix the problem, so let's just do that. |
In some cases (TBD) with Gradle 5.6.3 the build hangs for about 5 seconds while packaging the first cache artifacts. The behavior cannot be reproduced with Gradle 5.5.
Thread dump reveals that the packaging is not started because we are waiting for determining the local hostname:
The problem was seen on macOS Mojave. It could be reproduced with both Oracle 1.8.0_211 and also 11.0.5.
cc: @gradle/build-cache
The text was updated successfully, but these errors were encountered: