Questions tagged [maven-metadata]

Maven metadata is used to store versioning information about Maven artifacts. This metadata is produced by tools such a Maven, Gradle, SBT, Ivy et al and it is updated during the deployment of an artifact.

Maven metadata is used to store versioining information about Maven artifacts. This metadata is produced by tools such a Maven, Gradle, SBT, Ivy et al and it is updated during the deployment of an artifact.

Maven metadata can be used by tools to figure out:

  • What versions of an artifact exist

  • What timestamped versions of a snapshot artifact exist

  • What plugins exist under a groupId

Maven metadata is also used by the maven-indexer for producing searchable Lucene indexes.

Official Resources on Maven Metadata

See Also

73 questions
896
votes
12 answers

How do I tell Maven to use the latest version of a dependency?

In Maven, dependencies are usually set up like this: wonderful-inc dream-library 1.2.3 Now, if you are working with libraries that have frequent…
Anders Sandvig
  • 20,720
  • 16
  • 59
  • 73
153
votes
6 answers

Why is Maven downloading the maven-metadata.xml every time?

Below is the error I usually get when my internet connection is flanky when trying to build a web application with maven. My question is that, why does maven always have to download every time when the same app has been built earlier. What could…
quarks
  • 33,478
  • 73
  • 290
  • 513
42
votes
1 answer

How does Maven plugin prefix resolution work? Why is it resolving "findbugs" but not "jetty"?

I was doing some testing using Maven and realized that I can execute the findbugs goal of the Findbugs plugin without adding the plugin to the POM file. On the other hand, when I needed to run the run goal of the Jetty plugin, I was forced to add…
Jachk E
  • 500
  • 1
  • 5
  • 11
20
votes
4 answers

Finding list of versions available in a Maven repository for a specific plugin?

Given the following repository URL from my pom.xml how can I determine what the latest versions of spring and hibernate are available in the repository? http://repo1.maven.org/maven2
Jared
  • 39,513
  • 29
  • 110
  • 145
14
votes
1 answer

maven-metadata.xml is not updated when deploying to nexus

i am using Apache Maven 3.0 Nexus Open Source Edition, Version: 1.8.0.1 this is part of my pom.xml maven-deploy-plugin 2.5
Janning Vygen
  • 8,877
  • 9
  • 71
  • 102
12
votes
6 answers

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:…
IcyLemon
  • 139
  • 1
  • 5
12
votes
3 answers

How to rebuild maven-metadata.xml in Artifactory?

We're using Artifactory 3.9.2 and had to merge parts of two repositories (by copying over the artifacts) which had the same (SNAPSHOT-versioned) artifact. This screwed up the maven-metadata.xml. In Nexus its possible to simply rebuild the metadata…
carlspring
  • 31,231
  • 29
  • 115
  • 197
12
votes
4 answers

Maven build error No versions available for org.codehaus.jackson:jackson-core-asl:jar:[1.8,1.9) within specified range

I am getting following error since today morning while doing maven build. There are no specific changes for yesterday and today. Can someone help me to resolve this? I tried clearing all local repositories, changing jackson version to…
Abdul Azeez
  • 1,073
  • 4
  • 13
  • 21
8
votes
3 answers

How does Maven decide what version of a plugin to use, when you don't specify any?

I recognized that Maven not always uses the latest version of a plugin. For example org.codehaus.mojo:sonar-maven-plugin version 2.7 has beed released on 19th of October but on 23th of October, 2.6 was still used by Maven (mvn sonar:sonar). I even…
BlackEye
  • 775
  • 11
  • 25
7
votes
0 answers

How to ask maven to create maven-metadata.xml and not maven-metadata-local.xml?

For some reasons (not the concern of this post) amazon S3 is not a perfect host for maven repository. so i am building my maven application in a local machine and at some points in time (like every two days or so) i copy the whole hierarchy to…
MoienGK
  • 4,544
  • 11
  • 58
  • 92
7
votes
4 answers

How do I generate maven-metata.xml with maven-publish and the artifactory-gradle-plugin?

I've written a Gradle plugin in groovy and used Gradle to build it. I've got a local network Artifactory server that I publish the results to using the Gradle Artifactory plugin and the maven-publish plugin in Gradle. I have another Gradle build…
Stuporman
  • 773
  • 6
  • 26
7
votes
4 answers

How to force Maven to download maven-metadata.xml from the central repository?

What I want to do is to force Maven to download the 'maven-metadata.xml' for each artifact that I have in my local repository. The default Maven behaviour is to download only metadata from remote repositories (see this question). Why I want to do…
Alceu Costa
  • 9,733
  • 19
  • 65
  • 83
6
votes
1 answer

Migration to Maven 3.0.1 - Deploy fails with Error: 500 only for top most maven-metadata.xml

I'm testing out migration to Maven 3.0.1 from 2.2.1. All phases run fine except for the deploy phase. When I first run with 2.2.1, everything runs fine. Then I make the switch to 3.0.1 and run the same command and everything goes fine except for…
nemo
  • 1,504
  • 3
  • 21
  • 41
6
votes
2 answers

How do I prevent Maven from downloading maven-metadata.xml for an artifact that I already have in my repo?

I’m using Maven 3.2. I have this dependency in my pom.xml file (a WAR project) joda-time joda-time
Dave
  • 15,639
  • 133
  • 442
  • 830
5
votes
0 answers

How to deploy a snapshot artifact to a Maven repository and produce valid maven-metadata.xml using Gradle?

I have the following build.gradle script: apply plugin: 'java' apply plugin: 'maven' compileJava { targetCompatibility = "1.8" sourceCompatibility = "1.8" options.encoding = 'UTF-8' } ext.username = System.getProperty('username') !=…
carlspring
  • 31,231
  • 29
  • 115
  • 197
1
2 3 4 5