--Umgebung - CentOS Linux release 7.6.1810 (Core) - Apache Maven 3.2.5 --Java1.8.0_242 und Java1.6.0_41
$ mvn install -Dmaven.test.skip=true
...Kürzung...
[ERROR] Failed to execute goal on project ... Could not transfer artifact jsonic:jsonic:pom:1.2.0 from/to appfuse (http://static.appfuse.org/repository): static.appfuse.org: Name or service not known: Unknown host static.appfuse.org: Name or service not known -> [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 full debug logging.
[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/DependencyResolutionException
Es scheint, dass "http: // static.appfuse.org / repository" weg ist ... Ich wusste nicht einmal, dass es passiert ist
pom.xml
<?xml version="1.0" encoding="UTF-8"?>
...Kürzung...
<repositories>
...↓ Löschen ↓...
<repository>
<id>appfuse</id>
<url>http://static.appfuse.org/repository</url>
</repository>
...↑ Löschen ↑...
<repository>
<id>central</id>
<url>http://repo1.maven.org/maven2</url>
</repository>
...Kürzung...
Ich habe die Option -e im Fehler von Ereignis 1 gelernt.
To see the full stack trace of the errors, re-run Maven with the -e switch.
$ mvn install -Dmaven.test.skip=true -e
...Kürzung...
Caused by: org.apache.maven.wagon.TransferFailedException: Failed to transfer file: http://repo1.maven.org/maven2/junit/junit/4.7/junit-4.7.pom. Return code is: 501, ReasonPhrase: HTTPS Required.
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.resourceExists(AbstractHttpClientWagon.java:740)
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.resourceExists(AbstractHttpClientWagon.java:696)
at org.eclipse.aether.transport.wagon.WagonTransporter$PeekTaskRunner.run(WagonTransporter.java:518)
at org.eclipse.aether.transport.wagon.WagonTransporter.execute(WagonTransporter.java:427)
at org.eclipse.aether.transport.wagon.WagonTransporter.peek(WagonTransporter.java:398)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$PeekTaskRunner.runTask(BasicRepositoryConnector.java:376)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:350)
... 40 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/DependencyResolutionException
Central 501 HTTPS Required – Sonatype Support
pom.xml
<?xml version="1.0" encoding="UTF-8"?>
...Kürzung...
<repositories>
<repository>
<id>central</id>
<url>https://repo1.maven.org/maven2</url>
</repository>
...Kürzung...
$ mvn install -Dmaven.test.skip=true -e
Caused by: javax.net.ssl.SSLException: Received fatal alert: protocol_version
at sun.security.ssl.Alerts.getSSLException(Alerts.java:208)
at sun.security.ssl.Alerts.getSSLException(Alerts.java:154)
at sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1902)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1074)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1320)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1347)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1331)
at org.apache.maven.wagon.providers.http.httpclient.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:275)
at org.apache.maven.wagon.providers.http.httpclient.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:254)
at org.apache.maven.wagon.providers.http.httpclient.impl.conn.HttpClientConnectionOperator.connect(HttpClientConnectionOperator.java:123)
at org.apache.maven.wagon.providers.http.httpclient.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:318)
at org.apache.maven.wagon.providers.http.httpclient.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:363)
at org.apache.maven.wagon.providers.http.httpclient.impl.execchain.MainClientExec.execute(MainClientExec.java:219)
at org.apache.maven.wagon.providers.http.httpclient.impl.execchain.ProtocolExec.execute(ProtocolExec.java:195)
at org.apache.maven.wagon.providers.http.httpclient.impl.execchain.RetryExec.execute(RetryExec.java:86)
at org.apache.maven.wagon.providers.http.httpclient.impl.execchain.RedirectExec.execute(RedirectExec.java:108)
at org.apache.maven.wagon.providers.http.httpclient.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
at org.apache.maven.wagon.providers.http.httpclient.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.execute(AbstractHttpClientWagon.java:848)
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.resourceExists(AbstractHttpClientWagon.java:708)
... 46 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/DependencyResolutionException
Es scheint, dass JDK8 standardmäßig TLS v1.2 sein wird ... Ich frage mich, ob das Projekt JDK6 ist, also TLS v1.1 geworden ist. Diagnosing TLS, SSL, and HTTPS | Oracle Java Platform Group, Product Management Blog
Maven schlägt in Java7-Umgebung fehl (schwerwiegende Warnung erhalten: protocol_version) --Qiita
$ mvn install -Dmaven.test.skip=true -e -Dhttps.protocols=TLSv1.2
...Kürzung...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.980 s
[INFO] Finished at: 2020-04-14T21:34:21+09:00
[INFO] Final Memory: 22M/962M
[INFO] ------------------------------------------------------------------------
$ mvn install -Dmaven.test.skip=true -e
...Kürzung...
Caused by: org.eclipse.aether.transfer.ArtifactTransferException: Could not transfer artifact jsonic:jsonic:pom:1.2.0 from/to central (https://repo1.maven.org/maven2): Received fatal alert: protocol_version
at org.eclipse.aether.connector.basic.ArtifactTransportListener.transferFailed(ArtifactTransportListener.java:43)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:355)
at org.eclipse.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:67)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$DirectExecutor.execute(BasicRepositoryConnector.java:581)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector.get(BasicRepositoryConnector.java:249)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:520)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421)
... 35 more
Caused by: org.apache.maven.wagon.TransferFailedException: Received fatal alert: protocol_version
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:1085)
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:977)
at org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
at org.eclipse.aether.transport.wagon.WagonTransporter$GetTaskRunner.run(WagonTransporter.java:560)
at org.eclipse.aether.transport.wagon.WagonTransporter.execute(WagonTransporter.java:427)
at org.eclipse.aether.transport.wagon.WagonTransporter.get(WagonTransporter.java:404)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$GetTaskRunner.runTask(BasicRepositoryConnector.java:447)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:350)
... 40 more
Caused by: javax.net.ssl.SSLException: Received fatal alert: protocol_version
...Kürzung...
jsonic
mehr mit groupId jsonic
in der zentralen PositivitätSuchen mit Maven Repository: Suchen / Durchsuchen / Erkunden ...
pom.xml
<dependency>
<groupId>jsonic</groupId>
<artifactId>jsonic</artifactId>
<version>1.2.0</version>
</dependency>
jsonic
Es gab keine jsonic-Version 1.2.0 im zentralen Repository, daher werde ich sie aktualisieren
pom.xml
<dependency>
<groupId>net.arnx</groupId>
<artifactId>jsonic</artifactId>
<version>1.2.7</version>
</dependency>
.m2
sindDie Ursache und die Gegenmaßnahme sind [Umgang mit /home/path/.m2/repository/x.pom.part.lock (Berechtigung verweigert) in Maven der von Docker --Qiita erstellten Umgebung](https: // qiita.com/ponsuke0531/items/bae4b0ef57c4afcd4b7b)
Ich war wütend, als ich Java 1.8 im maven-compiler-plugin
spezifizierte.
$ mvn install -Dmaven.test.skip=true
...Kürzung...
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile)auf Projekt Projekt: Fatal error compiling: 1.8 ist eine ungültige Zielversion-> [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 full debug logging.
[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/MojoExecutionException
pom.xml
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<encoding>UTF-8</encoding>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
Referenz: Maven JDK 1.8 erkennen lassen --blog.kymmt.com Maven scheint Java zu verwenden, wenn es JAVA_HOME gibt.
#Maven verwendet Java1.6
$ mvn -v
...Kürzung...
Java version: 1.6.0_41, vendor: Sun Microsystems Inc.
Java home: /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.41.x86_64/jre
...Kürzung...
# JAVA_HOME ist auch Java1.6
$ printenv JAVA_HOME
/usr/lib/jvm/java-1.6.0-openjdk.x86_64
#Ich benutze Java1.8
$ java -version
openjdk version "1.8.0_242"
OpenJDK Runtime Environment (build 1.8.0_242-b08)
OpenJDK 64-Bit Server VM (build 25.242-b08, mixed mode)
Es gibt auch eine Möglichkeit, JAVA_HOME zu ändern, ohne es zu löschen.
# JAVA_HOME löschen,
$ unset JAVA_HOME
# .bash_Profil JAVA_Kommentieren Sie die HOME-Einstellungen aus
$ vi ~/.bash_profile
cat ~/.bash_profile
...Kürzung...
#JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk.x86_64
#export JAVA_HOME
#Wenn reflektiert
$ source ~/.bash_profile
[1]+ Done exec ibus-daemon -dx
# JAVA_HOME ist weg,
$ printenv JAVA_HOME
$
#Von Maven verwendetes Java ist Java1.Werden Sie 8
$ mvn -v
...Kürzung...
Java version: 1.8.0_242, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.242.b08-0.el7_7.x86_64/jre
...Kürzung...
#Dann verschwindet der Fehler
$ mvn install -Dmaven.test.skip=true
...Kürzung...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.202 s
[INFO] Finished at: 2020-04-15T11:33:39+09:00
[INFO] Final Memory: 18M/749M
[INFO] ------------------------------------------------------------------------
$ mvn install -Dmaven.test.skip=true -e
...Kürzung...
Caused by: org.eclipse.aether.transfer.ArtifactNotFoundException: Failure to find ... was cached in the local repository, resolution will not be reattempted until the update interval of local has elapsed or updates are forced
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.newException(DefaultUpdateCheckManager.java:231)
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.checkArtifact(DefaultUpdateCheckManager.java:206)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.gatherDownloads(DefaultArtifactResolver.java:585)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:503)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421)
... 40 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/DependencyResolutionException
[[Eclipse] Pom.xml verursacht Fehler aufgrund eines zusätzlichen Cache | nt-Memorandums](https://blog.integrityworks.co.jp/2016/03/24/eclipse-maven-pom-xml-error /)
.m2 / repository / org / apache / maven
$ rm -rf ~/.m2/repository/org/apache/maven
$ mvn install -Dmaven.test.skip=true -e
...Kürzung...
Caused by: org.eclipse.aether.resolution.ArtifactDescriptorException: Failed to read artifact descriptor for jp.co.hoge:hoge-framework-fuga:jar:3.0.0
at org.apache.maven.repository.internal.DefaultArtifactDescriptorReader.loadPom(DefaultArtifactDescriptorReader.java:337)
at org.apache.maven.repository.internal.DefaultArtifactDescriptorReader.readArtifactDescriptor(DefaultArtifactDescriptorReader.java:217)
at org.eclipse.aether.internal.impl.DefaultDependencyCollector.resolveCachedArtifactDescriptor(DefaultDependencyCollector.java:525)
...Kürzung...
Caused by: org.eclipse.aether.transfer.ArtifactNotFoundException: Failure to find ...was cached in the local repository, resolution will not be reattempted until the update interval of local has elapsed or updates are forced
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.newException(DefaultUpdateCheckManager.java:231)
at org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.checkArtifact(DefaultUpdateCheckManager.java:206)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.gatherDownloads(DefaultArtifactResolver.java:585)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:503)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421)
... 40 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/DependencyResolutionException
Erstellen Sie in diesem Fall ein Glas für das abhängige Projekt "hoge-framework-fuga" und beginnen Sie von vorne.
Wenn in Eclipse ein Fehler angezeigt wird, wenn Sie ein Projekt auswählen> [Maven]> [Projekt aktualisieren ...]
[Problems]Tab-Fehler
Failure to transfer javax.resource:connector:jar:1.0 from http://maven.ow2.org/maven2/ was cached in the local repository, resolution will not be reattempted until the update interval of ow2.org has elapsed or updates are forced. Original error: Could not transfer artifact javax.resource:connector:jar:1.0 from/to ow2.org (http://maven.ow2.org/maven2/): Cannot access http://maven.ow2.org/maven2/ with type legacy using the available connector factories: AetherRepositoryConnectorFactory, BasicRepositoryConnectorFactory
...Kürzung...
Failure to transfer javax.resource:connector:jar:1.0 from http://download.java.net/maven/2/ was cached in the local repository, resolution will not be reattempted until the update interval of java.net has elapsed or updates are forced. Original error: Could not transfer artifact javax.resource:connector:jar:1.0 from/to java.net (http://download.java.net/maven/2/): Cannot access http://download.java.net/maven/2/ with type legacy using the available connector factories: AetherRepositoryConnectorFactory, BasicRepositoryConnectorFactory
...Kürzung...
Pom vor dem Wechsel.xml
↓ Löschen ↓
<repository>
<id>java.net</id>
<url>http://download.java.net/maven/2/</url>
</repository>
↑ Löschen ↑
<repository>
<id>ow2.org</id>
↓ URL-Änderung ↓
<url>http://maven.ow2.org/maven2/</url>
</repository>
Als ich mein eigenes Glas spezifizierte, das sich nicht im Maven-Repository befand, wurde mir gesagt, dass es für dieses übergeordnete Projekt keinen Pom gibt ...
$ mvn install -Dmaven.test.skip=true -e
Caused by: org.eclipse.aether.transfer.ArtifactNotFoundException: Could not find artifact jp.co.hoge.fuga:hoge-fuga-project:pom:2.0.0 in local (file:/home/fuga/hoge-fuga-project/hoge-framework-core/../repo)
at org.eclipse.aether.connector.basic.ArtifactTransportListener.transferFailed(ArtifactTransportListener.java:39)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:355)
at org.eclipse.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:67)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$DirectExecutor.execute(BasicRepositoryConnector.java:581)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector.get(BasicRepositoryConnector.java:249)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:520)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421)
... 40 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/DependencyResolutionException
Ich mache so etwas wie "So installieren Sie in einem lokalen Repository 1" auf der folgenden Site. So geben Sie eine Bibliothek an, die sich nicht im Maven-Repository in pom.xml befindet --grep Tips *
Mir wurde gesagt "Artefakt konnte nicht gefunden werden jp.co.hoge.fuga: hoge-fuga-project: pom: 2.0.0"
{User Home} /. M2 / Repository / jp / co / hoge / fuga / hoge-fuga-project / pom / 2.0.0 /
Unter dem Verzeichnis
Ich habe das Projekt pom in "hoge-fuga-project-2.0.0.pom" umbenannt (.xml ist nicht erforderlich) und es kopiert.
Ich möchte die richtige Ursache und Gegenmaßnahmen kennen.