Dominik Kaspar created MNG-7144:
-----------------------------------
Summary: Spurious "Read timed out" errors during Maven dependency
resolution
Key: MNG-7144
URL: https://issues.apache.org/jira/browse/MNG-7144
Project: Maven
Issue Type: Bug
Affects Versions: 3.6.0
Reporter: Dominik Kaspar
Hello
We have hundreds of Maven builds each day, accessing a Nexus instance for
dependency resolution. While this works very well, we rarely observe spurious
download failures like this:
{noformat}
03:23:41 Downloading:
https://company/nexus/content/groups/nexus-repo/org/elasticsearch/elasticsearch/7.8.0/elasticsearch-7.8.0.jar
[... some more successful dependency downloads and 30 minutes idle waiting ...]
03:53:42 [ERROR] Failed to execute goal on project SomeProj: Could not resolve
dependencies for project
somegroup:someproj:jar:1.0.0-SNAPSHOT: Could not transfer artifact
org.elasticsearch:elasticsearch:jar:7.8.0
from/to nexus-repo (https://company/nexus/content/groups/nexus-repo): GET
request of:
org/elasticsearch/elasticsearch/7.8.0/elasticsearch-7.8.0.jar from nexus-repo
failed: Read timed out -> [Help 1]
{noformat}
Observations:
* The "missing" artifact always exists in the Nexus repository, sometimes it
has been there for years
* The read timeout always lasts exactly 30 minutes, which corresponds to the
default '{{maven.wagon.rto}}'
* Entries in the Nexus request.log suggest a successful transfer of the file,
with a 200 status code and a typically short elapsedTime (the 30156 ms in this
example were rather slow):
{noformat}
10.0.29.133 - jenkins [20/Feb/2021:03:24:11 +0100] "GET
/nexus/content/groups/nexus-repo/org/elasticsearch/elasticsearch/7.8.0/elasticsearch-7.8.0.jar
HTTP/1.1" 200 - 2916352 30156 "Apache-Maven/3.6.0 (Java 11.0.9.1; Linux
3.10.0-1160.11.1.el7.x86_64)"
{noformat}
* While in the above example, Maven 3.6.0 was used, we've observed the same
problem with other versions, including 3.0.4 and 3.5.4
While network problems cannot be ruled out, it seems odd that this happens so
rarely. What other causes could there be for such read timeouts? I'm out of
ideas of how to tackle this issue...
Regards,
Dominik
--
This message was sent by Atlassian Jira
(v8.3.4#803005)