[MNG-8145] GOAWAY received
- Dominant language
- Java
- Stars
- 5.3k
- Forks
- 3.1k
- Avg merge
- 20h 42m
- Merged PRs (30d)
- 297
Description
**[Filipe Roque](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=froque)** opened **[MNG-8145](https://issues.apache.org/jira/browse/MNG-8145?redirect=false)** and commented
When using a repository mirror with an nginx reverse proxy, HTTP/2 connection may fail due to reaching [keepalive_requests:](http://nginx.org/en/docs/http/ngx_http_core_module.html#keepalive_requests)
```java
[ERROR] Failed to execute goal org.apache.felix:maven-bundle-plugin:5.1.9:manifest (bundle-manifest) on project commons-io: Execution bundle-manifest of goal org.apache.felix:maven-bundle-plugin:5.1.9:manifest failed: Plugin org.apache.felix:maven-bundle-plugin:5.1.9 or one of its dependencies could not be resolved: Failed to collect dependencies at org.apache.felix:maven-bundle-plugin:jar:5.1.9 -> org.apache.maven:maven-archiver:jar:3.5.2: Failed to read artifact descriptor for org.slf4j:slf4j-api:jar:1.7.25: The following artifacts could not be resolved: org.slf4j:slf4j-api:pom:1.7.25 (absent): Could not transfer artifact org.slf4j:slf4j-api:pom:1.7.25 from/to maven-localrepository1 (https://localhost:8443/central): /127.0.0.1:42086: GOAWAY received -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the '-e' switch
[ERROR] Re-run Maven using the '-X' switch to enable verbose output
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException
```
This can be reproduced with:
```bash
git clone --quiet --branch rel/commons-io-2.16.1 git@github.com:apache/commons-io.git && cd commons-io
1. builds OK without mirror and empty local repository
TEMP_M2=$(mktemp -d)
echo $TEMP_M2
cat >$TEMP_M2/empty_settings.xml <
EOF
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/empty_settings.xml -Dmaven.repo.local=$TEMP_M2 -q clean verify -DskipTests
1. prepare a nginx mirror
mkdir -p /tmp/docker-ssl-proxy/
openssl req -subj '/CN=localhost' -x509 -newkey rsa:4096 -nodes -keyout /tmp/docker-ssl-proxy/key.pem -out /tmp/docker-ssl-proxy/cert.pem -days 365
cat >/tmp/docker-ssl-proxy/default.conf <$TEMP_M2/mirror_settings.xml <
maven-localrepository1
central
https://localhost:8443/central
EOF
export MAVEN_OPTS='-Djavax.net.ssl.trustStore=/tmp/docker-ssl-proxy/mykeystore.jks -Djavax.net.ssl.trustStorePassword=changeit'
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -q clean verify -DskipTests
```
Does not happen with, which only use HTTP/1.1
```java
/opt/maven/apache-maven-3.9.7/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -q clean verify -DskipTests
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -Dmaven.resolver.transport=apache -q clean verify -DskipTests
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -Dmaven.resolver.transport=wagon -q clean verify -DskipTests
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -Dmaven.resolver.transport=jdk -Daether.transport.jdk.httpVersion=HTTP_1_1 -q clean verify -DskipTests
/opt/maven/apache-maven-4.0.0-beta-3/bin/mvn -s $TEMP_M2/mirror_settings.xml -Dmaven.repo.local=$TEMP_M2 -Dmaven.resolver.transport=jdk -Daether.transport.jdk.httpVersion.maven-localrepository1=HTTP_1_1 -q clean verify -DskipTests
```
---
**Affects:** 4.0.0-beta-3
**Issue Links:**
- [MRESOLVER-584](https://issues.apache.org/jira/browse/MRESOLVER-584) Jetty / JDK transport: HTTP2 GOAWAY improvement
(_**"is duplicated by"**_)
- [MNG-8194](https://issues.apache.org/jira/browse/MNG-8194) Resolver 2.0.1
1 votes, 4 watchers
Contributor guide
Assessment
This issue has not been assessed yet.