Bug 1020299 - eclipse-m2e-core-1.4.0-7.fc20 fails with ClassNotFoundException: org.apache.http.client.methods.HttpUriRequest
eclipse-m2e-core-1.4.0-7.fc20 fails with ClassNotFoundException: org.apache.h...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: eclipse-m2e-core (Show other bugs)
20
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Mikolaj Izdebski
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-17 08:10 EDT by Mikko Tiihonen
Modified: 2014-01-15 04:44 EST (History)
2 users (show)

See Also:
Fixed In Version: 1.4.0-11
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-01-15 04:44:31 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Eclipse error log (5.42 KB, text/plain)
2013-10-17 08:10 EDT, Mikko Tiihonen
no flags Details

  None (edit)
Description Mikko Tiihonen 2013-10-17 08:10:51 EDT
Created attachment 813290 [details]
Eclipse error log

Tried on a newly created user account to rule out any problems from old configurations/versions laying around.

To reproduce:
  New -> Other -> Maven Project -> [x] simple project -> Next
  -> groupId: test, artifactId: test -> Finish

Installed eclipse packages:
eclipse-dtp-1.11.1-1.fc20.noarch
eclipse-ecf-core-3.6.1-1.fc20.noarch
eclipse-egit-3.1.0-1.fc20.noarch
eclipse-emf-2.9.1-1.fc20.noarch
eclipse-emf-core-2.9.1-1.fc20.noarch
eclipse-emf-xsd-2.9.1-1.fc20.noarch
eclipse-equinox-osgi-4.3.1-1.fc20.x86_64
eclipse-gef-3.9.1-0.1.gitb9f2e9.fc20.noarch
eclipse-jdt-4.3.1-1.fc20.x86_64
eclipse-jgit-3.1.0-1.fc20.noarch
eclipse-m2e-core-1.4.0-7.fc20.noarch
eclipse-moreunit-3.0.2-2.fc20.noarch
eclipse-p2-discovery-4.2.1-3.fc20.noarch
eclipse-pde-4.3.1-1.fc20.x86_64
eclipse-platform-4.3.1-1.fc20.x86_64
eclipse-swt-4.3.1-1.fc20.x86_64
eclipse-wtp-common-3.5.1-1.fc20.noarch
eclipse-wtp-servertools-3.5.1-1.fc20.noarch
eclipse-wtp-sourceediting-3.5.1-2.fc20.noarch
icu4j-eclipse-50.1.1-2.fc20.noarch
Comment 1 Mikolaj Izdebski 2013-10-17 08:29:19 EDT
The same problem is in Maven.
We're working on the fix now.
Comment 2 Gerard Ryan 2013-12-24 14:25:42 EST
(In reply to Mikolaj Izdebski from comment #1)
> The same problem is in Maven.
> We're working on the fix now.

Hi Mikolaj,

Is there any update on this? I've kinda just left it to the side since I'm assuming it's all one problem.

Thanks.
Comment 3 Mikolaj Izdebski 2013-12-30 07:12:35 EST
Sorry, I forgot to add a comment here.  I've already solved this and fixed locally on my system.  In this particular case there were a few missing symlinks to different apache-commons libraries.

The generic problem is that M2E spec file has a list of symlinks to Maven dependencies which you need to synchronize manually each time Maven dependency changes.  This is tedious and error prone.

Gerard, if you don't mind I'll take care of this bug and update M2E spec file to automatically symlink JARs.
Comment 4 Gerard Ryan 2013-12-30 12:48:40 EST
(In reply to Mikolaj Izdebski from comment #3)
> Sorry, I forgot to add a comment here.  I've already solved this and fixed
> locally on my system.  In this particular case there were a few missing
> symlinks to different apache-commons libraries.
> 
> The generic problem is that M2E spec file has a list of symlinks to Maven
> dependencies which you need to synchronize manually each time Maven
> dependency changes.  This is tedious and error prone.
> 
> Gerard, if you don't mind I'll take care of this bug and update M2E spec
> file to automatically symlink JARs.

I don't mind at all, in fact I'd be very grateful! Thanks! :)
Comment 5 Mikolaj Izdebski 2013-12-31 00:57:00 EST
Fixed in eclipse-m2e-core-1.4.0-9
Comment 6 Fedora Update System 2013-12-31 02:30:20 EST
eclipse-m2e-core-1.4.0-9.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/eclipse-m2e-core-1.4.0-9.fc20
Comment 7 Gerard Ryan 2014-01-02 18:19:18 EST
(In reply to Mikolaj Izdebski from comment #5)
> Fixed in eclipse-m2e-core-1.4.0-9

Hi Mikolaj,

Thanks for helping out on this. I've given that version a quick try, and I can't get the "New Maven Project" dialog to open at all:

>The selected wizard could not be started.
>Plug-in org.eclipse.m2e.core.ui was unable to load class >org.eclipse.m2e.core.ui.internal.wizards.MavenProjectWizard.
>An error occurred while automatically activating bundle org.eclipse.m2e.core.ui >(596).

Here's the traceback: http://paste.fedoraproject.org/65426/87024581/

It seems like that workaround for adding cglib is still necessary. I'm not able to build the latest version with xmvn-subst in my local mock (I may have some old packages there or something), so I've started a scratch on koji: http://koji.fedoraproject.org/koji/taskinfo?taskID=6351177

I likely won't get a chance to try that until tomorrow after work, so in the meantime: are there any other bad side-effects that you can think of to having that workaround re-added?

Hopefully I'll be able to make some attempts at m2e-core 1.5.0 milestone versions soon: I'm hoping it will bring some sanity back to this package. I've packaged some of the new dependencies, but it seems that there's some stuff in it that depends on the newer version of guava that we don't have yet (bug #1023832).

Thanks,
Gerard.
Comment 8 Gerard Ryan 2014-01-02 18:20:52 EST
Of course that would have been much better as an F20 scratch build. Sigh.

http://koji.fedoraproject.org/koji/taskinfo?taskID=6351185
Comment 9 Gerard Ryan 2014-01-03 18:23:40 EST
I've updated the bodhi update to re-add the cglib/aopalliance workaround, which fixed the problem for me that I mentioned in comment #7.
Comment 10 Mikolaj Izdebski 2014-01-04 04:04:13 EST
(In reply to Gerard Ryan from comment #7)
> Thanks for helping out on this. I've given that version a quick try, and I
> can't get the "New Maven Project" dialog to open at all:
> 
> >The selected wizard could not be started.
> >Plug-in org.eclipse.m2e.core.ui was unable to load class >org.eclipse.m2e.core.ui.internal.wizards.MavenProjectWizard.
> >An error occurred while automatically activating bundle org.eclipse.m2e.core.ui >(596).
> 
> Here's the traceback: http://paste.fedoraproject.org/65426/87024581/
> 
> It seems like that workaround for adding cglib is still necessary.

The problem appears to be caused by missing dependency exclusion on Guice and incorrect dependency scope on Sisu Plexus.  The original dependency on Sonatype Sisu has Guice exclusion, which is lost when Sonatype Sisu dependency is replaced with Eclipse Sisu.  Similarly scope "provided" is changed to default "compile".  Readding exclusion and resetting scope to "provided" fixes the problem you described.

> I'm not
> able to build the latest version with xmvn-subst in my local mock (I may
> have some old packages there or something), so I've started a scratch on
> koji: http://koji.fedoraproject.org/koji/taskinfo?taskID=6351177

You probably had too old Guice and/or Sisu.  I've tightened BuildRequires prevent that.

> I likely won't get a chance to try that until tomorrow after work, so in the
> meantime: are there any other bad side-effects that you can think of to
> having that workaround re-added?

Adding extra dependencies to Maven runtime will sooner or later lead to conflicts between different versions of the same library.

An example: Maven PMD Plugin requires CGlib.  If you try to run PMD plugin from M2E then two different versions of CGlib will be added to plugin class realm (one as dep of the plugin and the second one as dep of maven-runtime), which is likely to cause strange problems.


Gerard, I've pushed the fix and launched build.  If it works for you then I'll respin the update.
Comment 11 Gerard Ryan 2014-01-04 16:11:20 EST
(In reply to Mikolaj Izdebski from comment #10)
> Gerard, I've pushed the fix and launched build.  If it works for you then
> I'll respin the update.

Works for me. Thanks for the help, and the explanation of the exclusions (I knew there must have been a good reason!). I'll leave it to you so to change the update to this version...I'll be away for the next week.

Thanks again,
Gerard.
Comment 12 Mikolaj Izdebski 2014-01-05 05:01:28 EST
Update for Fedora 20 is requested for testing.
Comment 13 Fedora Update System 2014-01-15 01:09:09 EST
eclipse-m2e-core-1.4.0-11.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 14 Mikolaj Izdebski 2014-01-15 04:44:31 EST
I believe that this bug is fixed in eclipse-m2e-core-1.4.0-11,
which is available in updates for Fedora 20, so I am closing this bug now.

The build containing the fix can be found at Koji:
http://koji.fedoraproject.org/koji/buildinfo?buildID=488221

Note You need to log in before you can comment on or make changes to this bug.