You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Matt Clark <mc...@voyence.com> on 2007/11/02 17:39:02 UTC

RE: Problem with the Eclipse plugin

Sorry I got busy and din't respond.  I was using Maven 2.0.7.

I actually figured out the problem, and it seems pretty simple in retrospect.  I was using the 'bundle' packaging instead of the 'jar' packaging, and that was throwing off the eclipse plugin.  As soon as I changed to packaging 'jar', the eclipse plugin worked (and my bundle still looks good).

Hopefully that helps someone else.

Thanks!
Matt Clark


-----Original Message-----
From: mcculls@gmail.com on behalf of stuart.mcculloch@jayway.net
Sent: Fri 10/26/2007 10:11 AM
To: users@felix.apache.org
Subject: Re: Problem with the Eclipse plugin
 
the only thing I can think of is either you have a corrupted jar in
your local repository that's stopping maven from finding the bundle
life-cycle, or you're using a version of maven which for some reason
doesn't like the component description (ie. perhaps a regression of
some sort?)

you could try removing the
"~/.m2/repository/org/apache/felix/maven-bundle-plugin" directory in
your local repository, to force a clean reload of the 1.0.0 plugin
artifact.

otherwise, what version of maven are you using?

On 26/10/2007, Matt Clark <mc...@voyence.com> wrote:
> This looks like the culprit, but after searching for a while I can't
> find what would cause this.  Any thoughts?
>
> [DEBUG] Unable to find the lifecycle component in the extension
> org.codehaus.plexus.component.repository.exception.ComponentLookupExcept
> ion: Com
> ponent descriptor cannot be found in the component repository:
> org.apache.maven.
> lifecycle.mapping.LifecycleMappingbundle.
>         at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContai
> ner.java:323)
>         at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContai
> ner.java:312)
>         at
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContai
> ner.java:440)
>         at
> org.apache.maven.plugin.DefaultPluginManager.getPluginComponent(Defau
> ltPluginManager.java:1277)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.findExtension(Def
> aultLifecycleExecutor.java:1146)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.findOptionalMojos
> ForLifecycle(DefaultLifecycleExecutor.java:1099)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.bindLifecycleForP
> ackaging(DefaultLifecycleExecutor.java:999)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.constructLifecycl
> eMappings(DefaultLifecycleExecutor.java:980)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.forkProjectLifecy
>
> -----Original Message-----
> From: mcculls@gmail.com [mailto:mcculls@gmail.com] On Behalf Of Stuart
> McCulloch
> Sent: Friday, October 26, 2007 2:21 AM
> To: users@felix.apache.org
> Subject: Re: Problem with the Eclipse plugin
>
> On 26/10/2007, Matt Clark <mc...@voyence.com> wrote:
> >
> > Hi Stuart,
> >
> > Thanks for the response.  We're using eclipse plugin 2.4, and bundle
> > plugin 1.0.0.  Below is the POM, with names changed from our actual
> > group/artifact names.  All versions are specified in
> > dependencyManagement in the parent pom.
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <project>
> >   <parent>
> >     <artifactId>parent</artifactId>
> >     <groupId>com.acme</groupId>
> >     <version>1.0-SNAPSHOT</version>
> >   </parent>
> >   <modelVersion>4.0.0</modelVersion>
> >   <groupId>com.acme</groupId>
> >   <artifactId>foo</artifactId>
> >   <name>Foo Product</name>
> >   <version>1.0-SNAPSHOT</version>
> >   <packaging>bundle</packaging>
> >   <dependencies>
> >         <dependency>
> >         <groupId>junit</groupId>
> >               <artifactId>junit</artifactId>
> >               <scope>test</scope>
> >           </dependency>
> >         <dependency>
> >                 <groupId>com.acme</groupId>
> >                 <artifactId>foo-dependency</artifactId>
> >                 <version>${project.version}</version>
> >         </dependency>
> >   </dependencies>
> >   <build>
> >       <plugins>
> >         <plugin>
> >           <groupId>org.apache.felix</groupId>
> >           <artifactId>maven-bundle-plugin</artifactId>
> >           <extensions>true</extensions>
> >           <configuration>
> >             <instructions>
> >               <Dynamic-Imports>*</Dynamic-Imports>
> >               <Export-Package>com.acme.foo</Export-Package>
> >             </instructions>
> >           </configuration>
> >         </plugin>
> >       </plugins>
> >   </build>
> > </project>
>
>
> strange - when I use your POM (with the missing dependencies commented
> out)
> and the 1.0.0 release
> of the bundle-plugin, I get both a .classpath file and a .project file
> with
> both a Java nature and builder.
>
> also, the 1.0.0 release of the bundle-plugin was released several months
> ago, and once released the
> artifact never changes. So if this problem has only recently occurred I
> suspect it is probably an issue
> with the eclipse-plugin that has been triggered by a recent change in
> your
> project.
>
> what's the output when you use "mvn clean package eclipse:eclipse -X" ?
> any
> exceptions/warnings?
>
> As a result there is no .classpath file, and the .project file looks
> > like this:
> > <projectDescription>
> >   <name>foo</name>
> >   <comment/>
> >   <projects/>
> >   <buildSpec/>
> >   <natures/>
> > </projectDescription>
> >
> > Thanks,
> > Matt Clark
> > -----Original Message-----
> > From: mcculls@gmail.com [mailto:mcculls@gmail.com] On Behalf Of Stuart
> > McCulloch
> > Sent: Thursday, October 25, 2007 11:04 PM
> > To: users@felix.apache.org
> > Subject: Re: Problem with the Eclipse plugin
> >
> > On 26/10/2007, Matt Clark <mc...@voyence.com> wrote:
> > >
> > > Hi all,
> > > We're using the maven-bundle-plugin, which used to work great for
> us,
> > > but within the last two weeks something has happened which stops the
> > > maven eclipse:eclipse plugin from generating proper eclipse projects
> > for
> > > the 'bundle' type projects.
> >
> >
> > which versions of the bundle-plugin and eclipse-plugin are you using?
> >
> > We have packaging set to 'bundle', and when we run mvn eclipse:eclipse
> > > we get a project with no builders or natures in it.  This may be a
> bug
> > > with the eclipse plugin, but I thought I would see if anyone here
> had
> > > experienced that.
> >
> >
> > just tried it locally with the latest 1.1.0-SNAPSHOT of the
> > bundle-plugin
> > and
> > eclipse-plugin v2.4 and I get project natures and builders in the
> > .project
> > file
> >
> > can you provide a POM that recreates this issue?
> >
> > Thanks for any help,
> > >
> > > Matt Clark
> > >
> > >
> >
> >
> > --
> > Cheers, Stuart
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> > For additional commands, e-mail: users-help@felix.apache.org
> >
> >
>
>
> --
> Cheers, Stuart
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>


-- 
Cheers, Stuart

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org