Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aether-users] MetadataResult.metaData.file as a means to convey available versions

Carlo de Wolf wrote:

Whenever a version range, RELEASE or LATEST is requested (either in the
pom or through fmvn rewriting the request),
RepositorySystem.resolveMetadata is called. Then other components
(DefaultVersionResolver, DefaultPluginVersionResolver etc) will try to
open the file returned and parse it to get the versions overview.

Since JPP uses a different format it can't return any File which adheres
to maven-metadata.xml requirements.

AFAIU, you have basically two options: You either rewrite all those components reading metadata to deal with your style of metadata or you have your repository system generate the usual metadata files on the fly.

The latter case is the reason why repository connectors do not take URLs as input but artifacts/metadata. When the existing Maven components ask for for maven-metadata.xml which isn't already cached locally, a connector has the chance to either fetch the item as-is from its destination or generate it from other info.

And if neither a custom connnector nor your custom JPPLocalRepositoryManager fit your case, a custom MetadataResolver is another possibility to generate the metadata upon request.


Benjamin


Back to the top