WARNING] Unable to get resource 'org.codehaus.sonar:sonar-maven-plugin:pom:4.0' - maven

I am trying to run maven build with sonar on Ubuntu 10.04 version..but am getting below error. Can someone help me here what configuration I need to make..
Error is here:-
[INFO] Sonar version: 4.0
[INFO] Execute: org.codehaus.sonar:sonar-maven-plugin:4.0:sonar
Downloading: http://repo1.maven.org/maven2/org/codehaus/sonar/sonar-maven-plugin/4.0/sonar-maven-plugin-4.0.pom
[WARNING] Unable to get resource 'org.codehaus.sonar:sonar-maven-plugin:pom:4.0' from repository central (: Error transferring file: Connection timed out
Downloading: http://repo1.maven.org/maven2/org/codehaus/sonar/sonar-maven-plugin/4.0/sonar-maven-

Related

Maven deploy error HTTP method PUT is not supported by this URL

If I use this command I can upload into Nexus...
mvn deploy:deploy-file -Dfile=target/common-2.0.0.jar -DgroupId=com.test -DartifactId=test-common -Dversion=2.0.0 -Dpackaging=jar -DrepositoryId=TEST-REPO -Durl=https://nexus.xxx.xxxx.net/content/repositories/test
If I use this command
mvn deploy -DskipTests -DrepositoryId=TEST-REPO -DaltReleaseDeploymentRepository=releases::default::https://nexus.xxxx.xxxx.net/repository/test/
I get this error message...
[INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) # common ---
[INFO] Using alternate deployment repository releases::default::https://nexus.xxx.xxx.net/repository/test/
Uploading to releases: https://nexus.xxx.xxx.net/repository/test/com/test/common/2.0.0/common-2.0.0.jar
Uploading to releases: https://nexus.xxx.xxx.net/repository/test/com/test/common/2.0.0/common-2.0.0.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:08 min
[INFO] Finished at: 2019-05-16T14:55:35+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy (default-deploy) on project common:
Failed to deploy artifacts: Could not transfer artifact
com.test:common:jar:2.0.0 from/to releases (https://nexus.xxx.xxx.net/repository/test/):
Failed to transfer file: https://nexus.xxx.xxx.net/repository/test/common/common-2.0.0.jar. Return code is: 400, ReasonPhrase: HTTP method PUT is not supported by this URL. -> [Help 1]
Does anyone know if the command "deploy:deploy-file" uses HTTP POST but the command "deploy" uses HTTP PUT?
Or how I can force it to use HTTP POST?
Note:
The Nexus version is: Nexus Repository Manager OSS 2.14.4-03
Maven version is 3.0.5, and have tried 3.6.1
I found out that...
POST uploads are not supported in Nexus 3. Use a PUT instead.

How to deploy to Nexus Sonatype new Maven module

I'm creating new module for existing Maven project. When I try to mvn:install project from Idea it throughs these error:
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for kz.alfabank:type-ortalyk-bazar:bundle:1.0
[WARNING] 'version' contains an expression but should be a constant. # kz.alfabank:type-ortalyk-bazar:${kz.alfabank.type.ortalyk-bazar.version}, C:\Users\u8002\Documents\dev\alfa-bank\kz.alfabank.soa\kz.alfabank.soa\type-ortalyk-bazar\pom.xml, line 19, column 14
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building type-ortalyk-bazar 1.0
[INFO] ------------------------------------------------------------------------
Downloading: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-surefire-plugin/maven-metadata.xml from/to public (http://vserver266:8081/nexus/content/groups/public): Failed to transfer file: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata.xml. Return code is: 504 , ReasonPhrase:Connection Timed Out.
Downloading: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-install-plugin/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-install-plugin/maven-metadata.xml from/to public (http://vserver266:8081/nexus/content/groups/public): Failed to transfer file: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-install-plugin/maven-metadata.xml. Return code is: 504 , ReasonPhrase:Connection Timed Out.
Downloading: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-deploy-plugin/maven-metadata.xml from/to public (http://vserver266:8081/nexus/content/groups/public): Failed to transfer file: http://vserver266:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml. Return code is: 504 , ReasonPhrase:Connection Timed Out.
Downloading: http://vserver266:8081/nexus/content/groups/public/kz/alfabank/type-ortalyk-bazar/1.0/type-ortalyk-bazar-1.0.jar
Downloading: https://repo.maven.apache.org/maven2/kz/alfabank/type-ortalyk-bazar/1.0/type-ortalyk-bazar-1.0.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 03:03 min
[INFO] Finished at: 2018-10-11T14:01:00+06:00
[INFO] Final Memory: 14M/167M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project type-ortalyk-bazar: Could not resolve dependencies for project kz.alfabank:type-ortalyk-bazar:bundle:1.0: Could not find artifact kz.alfabank:type-ortalyk-bazar:jar:1.0 in public (http://vserver266:8081/nexus/content/groups/public) -> [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
We use as a repository Sonatype Nexus 2.11.4. Why Maven looks for newly created module in Nexus repository? And seems that some metadata files cannot be downloaded from Nexus :/
If dependencies are not available in local repository or other dependencies are not built or downloaded prior to the current module build that is when it looks within the remote repositories.
Please do look for the artifact kz.alfabank:type-ortalyk-bazar:jar:1.0 is present in the in your .m2 repo
Note: If you are using IntelliJ within the setting try offline mode

Nexus Artefact Upload Failure

using maven deploy command, I tried to upload artefacts of size (440 MB) in Nexus repository(Nexus Version : nexus-professional-2.13.0-01). Maven version is 3.5.2. Configured my proxy server details in settings.xml
mvn -e -X deploy:deploy-file -DgroupId=de.test.oca -DartifactId=wildfly-image -Dversion=0.0.1-SNAPSHOT -Dpackaging=tar.gz -Dfile=oca-wildfly-image-0.0.1-snapshot.tar.gz -DrepositoryId=oca-snapshots -Durl=http://xx.xx.xx:8081/nexus/content/repositories/oca-snapshots
Error Message :
Uploaded to oca-snapshots: http://xx.xx.xx:8081/nexus/content/repositories/oca-snapshots/de/test/oca/wildfly-image/0.0.1-SNAPSHOT/wildfly-image-0.0.1-20180117.094348-1.pom (446 B at 1.2 kB/s)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 07:07 min
[INFO] Finished at: 2018-01-17T10:50:54+01:00
[INFO] Final Memory: 10M/309M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy-file (default-cli) on project standalone-pom: Failed to deploy artifacts: Could not transfer artifact de.test.oca:wildfly-image:tar.gz:0.0.1-20180117.094348-1 from/to oca-snapshots (http://xx.xx.xx:8081/nexus/content/repositories/oca-snapshots): Connection reset -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy-file (default-cli) on project standalone-pom: Failed to deploy artifacts: Could not transfer artifact de.test.oca:wildfly-image:tar.gz:0.0.1-20180117.094348-1 from/to oca-snapshots (http://xx.xx.xx:8081/nexus/content/repositories/oca-snapshots): Connection reset
In Nexus GUI, I can able to find the tar.gz file uploaded. When I checked nexus.log, I found error message as
jvm 1 | 2018-01-17 14:27:17,706+0100 INFO [qtp1148931253-265705] admin com.sonatype.nexus.plugins.outreach.internal.outreach.SonatypeOutreach - Could not download page bundle
jvm 1 | org.apache.http.conn.ConnectionPoolTimeoutException: Timeout waiting for connection from pool
jvm 1 | 2018-01-17 14:27:47,710+0100 INFO [qtp1148931253-265708] admin com.sonatype.nexus.plugins.outreach.internal.outreach.SonatypeOutreach - Could not download page bundle
jvm 1 | org.apache.http.conn.ConnectionPoolTimeoutException: Timeout waiting for connection from pool
I tried to Upload another file with file sizw of 300MB, it works fine.
Is there any file size limit in the Nexus.
There is no filesize limit in Nexus itself. However there might be timeout issues, performance issues with the app or other issues with the underlying OS and filesystem.

Build issues with Hadoop on windows

I am trying to build hadoop on windows and I am following this link http://opensourceforu.efytimes.com/2015/03/getting-started-with-hadoop-on-windows/. However when I try to build the code using the command
mvn package -Pdist,native-win -DskipTests Dtar
I am getting the following error
[DEBUG] Writing tracking file C:\Users\SS\.m2\repository\org\s
onatype\plexus\plexus-cipher\1.4\_remote.repositories
[DEBUG] Writing tracking file C:\Users\SS\.m2\repository\org\s
onatype\plexus\plexus-cipher\1.4\plexus-cipher-1.4.jar.lastUpdated
[DEBUG] Writing tracking file C:\Users\SS\.m2\repository\org\a
pache\maven\plugin-tools\maven-plugin-annotations\3.4\_remote.repositories
[DEBUG] Writing tracking file C:\Users\SS\.m2\repository\org\a
pache\maven\plugin-tools\maven-plugin-annotations\3.4\maven-plugin-annotations-3
.4.jar.lastUpdated
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 25:08 min
[INFO] Finished at: 2016-03-21T17:02:06+05:30
[INFO] Final Memory: 13M/173M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project hadoop-maven-plugins: Could not resolv
e dependencies for project org.apache.hadoop:hadoop-maven-plugins:maven-plugin:2
.7.2: Could not transfer artifact org.apache.maven:maven-model:jar:3.0 from/to c
entral (https://repo.maven.apache.org/maven2): GET request of: org/apache/maven/
maven-model/3.0/maven-model-3.0.jar from central failed: SSL peer shut down inco
rrectly -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal o
n project hadoop-maven-plugins: Could not resolve dependencies for project org.a
pache.hadoop:hadoop-maven-plugins:maven-plugin:2.7.2: Could not transfer artifac
t org.apache.maven:maven-model:jar:3.0 from/to central (https://repo.maven.apach
e.org/maven2): GET request of: org/apache/maven/maven-model/3.0/maven-model-3.0.
jar from central failed
at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDe
pendencies(LifecycleDependencyResolver.java:221)
at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.resol
veProjectDependencies(LifecycleDependencyResolver.java:127)
at org.apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAr
eResolved(MojoExecutor.java:245)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor
.java:199)
I am using a windows 7 enterprise 64 bit machine and there is no proxy configured in IE. Can somebody help me to resolve this issue?
Thank you,
Using openssl s_client -connect servername:443 you can debug what protocol the server supports and perform tests by forcing flags like ssl2, ssl2, check this

How to resolve BUILD FAILURE project tutorial DevKit mulesoft

I'm trying to use for the first time DevKit of mulesoft, I'm following the guide of mulesoft at link: http://www.mulesoft.org/documentation/display/current/Tutorial+-+Barn+Connector. I have installed DevKit Plugin from Mule studio and after that I have tried to create the Anypoint Connector Project like the guide said me, but I have found the problem with Maven.
My error is:
[INFO] Downloading: http://repository.mulesoft.org/releases/org/apache/maven/plugins/maven-jar-plugin/maven-metadata.xml
[INFO] Downloading: http://snapshots.repository.codehaus.org/org/apache/maven/plugins/maven-jar-plugin/maven-metadata.xml
[INFO] Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata.xml
[INFO] Downloading: http://repository.mulesoft.org/snapshots/org/apache/maven/plugins/maven-jar-plugin/maven-metadata.xml
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml from/to codehaus-plugin-snapshots (http://snapshots.repository.codehaus.org): Connect to http-proxy.xxx.com:80 [http-proxy.xxx.com/xxx] failed: Connection timed out: connect
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml from/to mulesoft-plugin-releases (http://repository.mulesoft.org/releases/): Connect to http-proxy.xxx.com:80 [http-proxy.xxx.com/xxx] failed: Connection timed out: connect
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml from/to mulesoft-plugin-snapshots (http://repository.mulesoft.org/snapshots/): Connect to http-proxy.xxx.com:80 [http-proxy.xxx.com/xxx] failed: Connection timed out: connect
[WARNING] Could not transfer metadata org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml from/to central (https://repo.maven.apache.org/maven2): Connect to http-proxy.xxx.com:80 [http-proxy.xxx.com/xxx] failed: Connection timed out: connect
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:27 min
[INFO] Finished at: 2015-03-11T13:05:19+01:00
[INFO] Final Memory: 16M/223M
[INFO] ------------------------------------------------------------------------
[ERROR] Error resolving version for plugin 'org.apache.maven.plugins:maven-jar-plugin' from the repositories [local (C:\Users\s\.m2\repository), codehaus-plugin-snapshots (http://snapshots.repository.codehaus.org), mulesoft-plugin-releases (http://repository.mulesoft.org/releases/), mulesoft-plugin-snapshots (http://repository.mulesoft.org/snapshots/), central (https://repo.maven.apache.org/maven2)]: Plugin not found in any plugin repository -> [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/PluginVersionResolutionException
How to resolve it?
Seems like something happened when maven was downloading the dependencies, try generating another new connector.
Did you check for the existence of Maven JAR with the specified version?

Resources