Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] Plugin Nature Questions

Hi Igor-
Thanks for the replies, see inline:

On 5/18/2013 8:44 AM, Igor Fedorenko wrote:
On 2013-05-17 10:37 PM, David Erickson wrote:
Hi everyone-
I am working with a many-module project using the maven-bundle-plugin to
create OSGi-compatibile jar files.  I've noticed a few odd things and
have a couple questions:

1) Each of the projects has the plugin nature after I import it, what is
adding this when imported with Maven? And is there some custom code that
is connecting the maven-bundle-plugin to PDE? Because for example I can
right click on the project -> Plug-in Tools -> Open Manifest and it will
open when in fact there is no file in the source directory backing this.


m2e-tycho enables PDE nature for projects that use maven-bundle-plugin
(m-b-p for short). m-b-p generates bundle manifest in
target/classes/META-INF directory by default, which is hidden in Package
Explorer view but you can see it in Navigator view, for example, or
directly on filesystem. Note, however, that PDE does not fully support
non-standard (for PDE) bundle manifest location, so I usually recommend
configuring m-b-p to use <basedir>/META-INF inside m2e workspace.

I tried this and I'm cautiously optimistic that it fixed the problem I was seeing in #3.


2) There is a .launch file saved in one of the projects, however after a
clean code checkout and initial import into Eclipse, when looking at the
corresponding run configuration it is missing some of the projects in
the workspace, like it does not recognize they are PDE projects.  If I
select all the workspace projects and right click -> Maven -> Update
Project, after the rebuild the configuration will properly find all
projects in the workspace. Doing this one by one works as well, and
Project ->  Clean does NOT work.


Have not seen this, but I assume the problem is somewhere between
m2e-tycho and PDE. My workspaces are usually long lived, so there is a
chance I may have forgot about it :-)

:) Any suggestion on how I could help debug this? I saw some errors printed when I configured Eclipse's log to show debug (eclipse.log.level=DEBUG in config.ini), but what I'd really like is to get debug logging from m2eclipse and from the the underlying Maven builds (-X -e) it executes on that very first automatic build after importing the existing Maven projects.


3) Each plug-in in the run configuration has a red X on the icon and is
listed as "(out of sync)", I haven't found any way to resolve this, no
quantity of refreshing, setting the workspace to auto refresh will
resolve this.  Is it related to the MANIFEST.MF being auto generated
somehow?


Does (right-click)->Maven->Update_Project clear the error marker? What
is exact marker message?

Unfortunately not, the exact error can only be viewed when looking at the run configuration, in the workspace area of the bundles list the icon will have the red X and the normal bundle name will exactly have "(out of sync)" appended to the end. However it looks like your suggestion for #1 may fix this.

Thanks,
David


Back to the top