Hey,

I had the exact same problem : open source nexus configured.
I found out that the Sonatype public proxy, configured in the public
proxy references the 2.0-alpha-5-SNAPSHOT version of the maven
archetype plugin. Maven somehow doesn't seem like willing to get it
though.
As a workaround, I temporarily disabled Sonatype public proxy from my
public repositories configuration in nexus, rebuilt my meta data (on
nexus and in my local repo), and gave another successful try...
Maybe there's something I don't get in nexus and / or snpashot
repository configuration that makes maven try to get a snopshot
version on a repository with release dependency management policy.

Hope this will help...
Hervé

On 18 juin, 17:26, Marvin Froeder <[email protected]> wrote:
> Look at your public repo metadata, it should be wrong there....
>
> VELO
>
>
>
> On Thu, Jun 18, 2009 at 11:39 AM, James Cook <[email protected]> wrote:
> > Thanks. I am running a company-wide Nexus server. My public group _doesn't_
> > contain Apache or Codehaus snapshot repositories, only their release
> > repositories.
>
> > I thought that I may have something wrong in my local repository metadata,
> > so I deleted it. It didn't help.
>
> > I'm including my log file. It looks like the offending line is:
> > [DEBUG] maven-archetype-plugin: resolved to version 2.0-alpha-5-SNAPSHOT
> > from repository central
>
> > So, the repository is saying the latest version of this plugin is
> > 2.0-alpha-5-SNAPSHOT, but that artifact is not in my repository. Perhaps
> > something is screwed up such that I am seeing metadata from Snapshot
> > repositories, but only artifacts from release repositories?
>
> > I've worked around my current problem by hardcoding the 2.0-alpha-4 version
> > into the archetype command:
>
> > mvn org.apache.maven.plugins:maven-archetype-plugin:2.0-alpha-4:generate \
> >       -DarchetypeRepository=
> >http://repository.sonatype.org/content/groups/public\
> >       -DarchetypeGroupId=org.sonatype.flexmojos \
> >       -DarchetypeArtifactId=flexmojos-archetypes-library \
> >       -DarchetypeVersion=3.1.0
>
> > -- jim
>
> > Maven version: 2.0.9
> > Java version: 1.5.0_16
> > OS name: "mac os x" version: "10.5.7" arch: "i386" Family: "unix"
> > [DEBUG] Building Maven user-level plugin registry from:
> > '/Users/jimcook/.m2/plugin-registry.xml'
> > [DEBUG] Building Maven global-level plugin registry from:
> > '/Users/jimcook/Libs/apache-maven-2.0.9/conf/plugin-registry.xml'
> > [INFO] Scanning for projects...
> > [INFO] Searching repository for plugin with prefix: 'archetype'.
> > [DEBUG] Loading plugin prefixes from group: org.apache.maven.plugins
> > [INFO] org.apache.maven.plugins: checking for updates from central
> > [DEBUG] Loading plugin prefixes from group: org.codehaus.mojo
> > [INFO] org.codehaus.mojo: checking for updates from central
> > [INFO] artifact org.apache.maven.plugins:maven-archetype-plugin: checking
> > for updates from central
> > [DEBUG] maven-archetype-plugin: resolved to version 2.0-alpha-5-SNAPSHOT
> > from repository central
> > [INFO] snapshot
> > org.apache.maven.plugins:maven-archetype-plugin:2.0-alpha-5-SNAPSHOT:
> > checking for updates from central
> > [DEBUG] repository metadata for: 'snapshot
> > org.apache.maven.plugins:maven-archetype-plugin:2.0-alpha-5-SNAPSHOT' could
> > not be found on repository: central
> > [DEBUG] maven-archetype-plugin: using locally installed snapshot
> > [DEBUG] Trying repository central
> > Downloading:
> >http://repo.example.org/maven2/content/groups/public/org/apache/maven...
> > [DEBUG] Artifact not found - using stub model: Unable to locate resource in
> > repository
>
> >   org.apache.maven.plugins:maven-archetype-plugin:pom:2.0-alpha-5-SNAPSHOT
>
> > from the specified remote repositories:
> >   myrepo (http://repo.example.org/maven2/content/groups/public)
>
> > On Thu, Jun 18, 2009 at 10:06 AM, Marvin Froeder <[email protected]>wrote:
>
> >> So you have you own company nexus instance, right?
> >> I guess the problem is on your public group.... it probably contains the
> >> 2.0-alpha-5-SNAPSHOT included....  so if you don't wanna SNAPSHOT on your
> >> group, you must configure the group to not include SNAPSHOTs....  trying to
> >> get that "filtered" on client side may be a problem, cause maven will
> >> download metadatas containing the SNAPSHOTs.
>
> >> I hope that helps.
>
> >> VELO
>
> >> On Thu, Jun 18, 2009 at 10:40 AM, oravecz <[email protected]> wrote:
>
> >>> This is probably more a general Maven question, but I think it
> >>> pertains to a hard-coded version dependency in a flex-mojos pom, I
> >>> thought I would ask it here. I am following the Nexus documentation
> >>> for setting up a company wide repository. I have modified my
> >>> settings.xml to this:
>
> >>> <settings>
> >>>  <mirrors>
> >>>    <mirror>
> >>>      <id>myrepo</id>
> >>>      <mirrorOf>*</mirrorOf>
> >>>      <url>http://repo.example.org/maven2/content/groups/public</url>
> >>>    </mirror>
> >>>  </mirrors>
> >>> ...
> >>> </settings>
>
> >>> However, when I follow the instructions for creating a flex-mojos
> >>> archetype, I get an exception.
>
> >>> mvn archetype:generate
> >>>    -DarchetypeRepository=http://repository.sonatype.org/content/
> >>> groups/public <http://repository.sonatype.org/content/%0Agroups/public>
> >>>    -DarchetypeGroupId=org.sonatype.flexmojos
> >>>    -DarchetypeArtifactId=flexmojos-archetypes-application
> >>>    -DarchetypeVersion=3.0.0
>
> >>> [INFO] A required plugin was not found: Plugin could not be found -
> >>> check that the goal name is correct: Unable to download the artifact
> >>> from any repository
> >>> org.apache.maven.plugins:maven-archetype-plugin:maven-plugin:2.0-
> >>> alpha-5-SNAPSHOT
>
> >>> The problem is that the 2.0-alpha-5-SNAPSHOT version of the plugin is
> >>> in the Apache snapshot repository and not the release repository. I am
> >>> mirroring only releases. Is there a way for me to get this to work
> >>> without making some kind of sweeping change in my company repository?
>
> >>> -- jim

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Flex Mojos" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/flex-mojos?hl=en?hl=en

http://blog.flex-mojos.info/
-~----------~----~----~----~------~----~------~--~---

Reply via email to