The timestamp in snapshot jar's maven-metadata.xml is more than a second than the actual jar's timestamp?
I encountered a quirky problem: I used "mvn deploy" (Maven 3.3.9, Jenkins 2.45, Nexus 2.12.0) to deploy a snapshot jar to my nexus in jenkins, result as below (suppose the jar name is userdao.jar): Uploaded: myNexusIp/nexus/content/repositories/snapshots/xxx/1.0-SNAPSHOT/userdao-1.0-20170512.111840-6.jar Uploaded: myNexusIp/nexus/content/repositories/snapshots/xxx/1.0-SNAPSHOT/maven-metadata.xml The build was successful and everything was OK. But when I built another maven project that depended above userdao.jar, error occurred as below: Could not find artifact userdao:jar:1.0-20170512.111840-6 in public (http://myNexusIp/nexus/content/groups/public/) After positioning I found that the timestamp in maven-metadata.xml in the nexus was more than a second than the actual jar's timestamp! As below: in maven-metadata.xml: 1.0-20170512.111840-6 actual existing snapshot jar: userdao-1.0-20170512.111839-6.jar Because userdao-1.0-20170512.111840-6.jar did not exist in Nexus, the right one should be userdao-1.0-20170512.111839-6.jar, so it errors. Who can tell me why and how to resolve it?
The first thing to try is to rebuild your metadata on the repo where you uploaded your snapshot artifact. See "Managing Scheduled Tasks" Rebuild Maven Metadata Files This task will rebuild the maven-metadata.xml files with the correct information and will also validate the checksums (.md5/.sha1) for all files in the specified Repository/Group. Typically this task is run manually to repair a corrupted repository.
How to use downloaded version of andromda to create and compile Project?
Github authentication: how to use Github as Maven repo when repo is private
How can I find doc for -Dparameters for maven plugin
What's the difference between maven-rpm-plugin and rpm-maven-plugin
flexmojos ignoring configuration?
Error in maven :No plugin found for the prefix 'get'
Maven site:deploy (with DIFFERENT url) during “deploy” goal (when in testing profile)?
Plugin execution not covered by lifecycle configuration maven error
Andromda Project Creation Using Maven
Maven release plugin adding trunk folder under release tag for release:prepare goal
Why maven meta-data doesn't include specific version of all artifacts
Error when using javac: “javac: invalid flag: -s”
Executing acceleo project with maven
create html file from pom.xml
Using javah maven-antrun-plugin with jdk 1.7, classes.jar became tools.jar
Maven: Report using deprecated classes / methods