Error 409 Conflict when deploy with Jenkins in Anypoint Platform (CloudHub) - maven

We deployed without problems in Anypoint Platform (CloudHub) using Jenkins. Now having problems.
The log shows that the answer is 409 Conflict when trying to deploy.
This is the exact error:
[ERROR] Failed: 409 Conflict: {"status": 409, "message": "Application not updated"}
[ERROR] Failed to deploy myApplicationName: Failed to deploy application myApplicationName
Also:
[ERROR] Failed to execute goal org.mule.tools.maven:mule-maven-plugin:2.2.1:deploy (deploy)
on project myApplicationName:
Failed to deploy [/usr/local/apache-tomcat-9.0.4/.jenkins/workspace/JDE System API/myApplicationName/
target/myApplicationName-1.0.6.zip] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal
As possible solutions we find changing the Maven to 2.2.1 but it is the one we are using.
Any solution?

Migrating to Mule Maven Plugin latest release for Mule 3.x (2.3.3) should resolve that issue. Note that migrating from earlier than 2.3.0 requires adapting the plugin configuration. The link above points to documentation.

Related

maven-deploy-plugin goal failed to achieved - working fine in window agent, build failed in Unix agent (Azure Pipeline)

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy (default-deploy) on project **xxxxxxxxxx**: Execution default-deploy of goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy failed: An API incompatibility was encountered while executing org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy: java.lang.NoSuchMethodError: org.apache.maven.wagon.shared.http.AbstractHttpClientWagon.getBufferCapacityForTransfer(J)I
Same pom.xml was used in two agents but error occurs in unix agent. Anyone knows what is the possible reason for the error?
The version of Maven on the Unix system is probably old and not compatible with the Mule Maven Plugin. Try upgrading to a newer version that is compatible.
The issue is documented at this KB article: https://help.mulesoft.com/s/article/An-API-incompatibility-was-encountered-while-executing-org-apache-maven-plugins-maven-deploy-plugin-while-deploying-an-asset-to-Exchange-using-Exchange-Maven-Facade-v3

maven build fails with weird mockito dependecy attempted and failed

I'm trying to build and run the maven project as mentioned here https://github.com/gateio/gateapi-java/tree/master/example. As far as I can see the pom.xml doesn't even mention mockito but the maven build fails with
[ERROR] Failed to execute goal on project gateapi-demo: Could not resolve dependencies for project io.gate.apidemo:gateapi-demo:jar:1.0-SNAPSHOT: Failed to collect dependencies at io.gate:gate-api:jar:5.15.3: Failed to read artifact descriptor for io.gate:gate-api:jar:5.15.3: Could not transfer artifact io.gate:gate-api:pom:5.15.3 from/to mockito (https://mvnrepository.com/artifact/org.mockito/mockito-all): authorization failed for https://mvnrepository.com/artifact/org.mockito/mockito-all/io/gate/gate-api/5.15.3/gate-api-5.15.3.pom, status: 403 Forbidden -> [Help 1]
What is going on here?

gitlabci integration with sonar

Hi Everyone I’m trying to integrate with the sonar below is the error i am facing
Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.7.0.1746:sonar (default-cli) on project XXXXX: Unable to register extension fr.cnes.sonar.plugins.icode.check.ICodeSensor from plugin ‘icode’: javax/xml/bind/JAXBException: javax.xml.bind.JAXBException -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.7.0.1746:sonar (default-cli) on project XXXXX: Unable to register extension
My code is java 11 and I have added the related dependency.
Can anyone help me in this one?
The version of Sonar i-Code CNES plugin you use is not compatible with your java version (11).
Update your version of Sonar i-Code CNES plugin to >2.0.0 and it will work.

Logging error when executing Maven SonarQube plugin

I've been facing an issue with Maven SonarQube plugin (v2.6) when Maven version is recent (strictly larger than 3.1).
Here is what I run:
mvn clean verify -Psonar
mvn org.codehaus.mojo:sonar-maven-plugin:2.6:sonar -Psonar
The first invocation makes sure sources are compiled and JaCoCo agent is prepared.
The interesting part comes, when the second command is run:
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project merlin-schema: Error setting Log implementation. Cause: java.lang.reflect.InvocationTargetException: org/slf4j/Marker -> [Help 1]
Any fix to be published?
Replacing default Maven logging implementation is currently not supported. Ticket created: http://jira.sonarsource.com/browse/MSONAR-122

Need help on Sonar Jasmine spec failures

I'm getting the following exception when trying to build the sonar dashboard using maven (mvn sonar:sonar)
Failed to execute goal com.github.searls:jasmine-maven-plugin:1.2.0.0:test (default) on project sample-web: There were Jasmine spec failures. -> [Help 1]
Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.0:sonar (default-cli) on project operative-global: Can not execute Sonar: Unable to execute maven plugin: Exception during execution of org.codehaus.mojo:cobertura-maven-plugin:2.5.1:cobertura -> [Help 2]
Could someone help me with the suggestions/comments to resolve the problem?
Thanks,
Kathir
This was related to compatability issues. The issue gets resolved after upgrading the jars to the latest version.

Resources