Maven Eclipse Plugin
  1. Maven Eclipse Plugin
  2. MECLIPSE-618

MANIFEST files generated by plugin are empty when they shouldnt

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 2.7
    • Fix Version/s: None
    • Component/s: M2Eclipse support
    • Labels:
      None
    • Environment:
      Any

      Description

      MANIFEST.MF files generated by the plugin are empty, therefore a correct deployment of an EAR project on an application server such as JBoss will fail with classloading issues.

      After a close look at the source code the problem comes from the fact that the dependencies resolving is disabled in the mojo, in order to not feed the .classpath, but having this side-effect.

      I suggest resolving dependencies in any case, and adding a property instead to filter dependencies in the .classpath generation.
      therefore :
      1: add boolean property to EclipsePlugin : ignoreDeps
      2: add boolean property to EclipseWriterConfig : ignoreDeps
      3: in M2EclipseMojo>>setupExtra() :

      • //setResolveDependencies( false );
      • setIgnoreDeps(true);
        4: in EclipsePlugin>>createEclipseWriterConfig(IdeDependency[]) :
      • call config.setIgnoreDeps(isIgnoreDeps());
        5: in EclipseClasspathWriter>>write() :
      • test against if (!config.isIgnoreDeps()) around lines 348 to 387 in order to skip writing of M2_REPO... dependencies

      Tested here, works like a charm

        Activity

        Andre Doherty created issue -
        Hide
        Michael Osipov added a comment -

        Please refer to https://cwiki.apache.org/confluence/display/MAVEN/The+Great+JIRA+Cleanup+of+2014 if you're wondering why this issue was closed out.

        Show
        Michael Osipov added a comment - Please refer to https://cwiki.apache.org/confluence/display/MAVEN/The+Great+JIRA+Cleanup+of+2014 if you're wondering why this issue was closed out.
        Michael Osipov made changes -
        Field Original Value New Value
        Resolution Won't Fix [ 2 ]
        Status Open [ 1 ] Closed [ 6 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 10:00:37 UTC 2015 [ 1428228037919 ]
        Mark Thomas made changes -
        Workflow jira [ 12721004 ] Default workflow, editable Closed status [ 12750574 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 23:47:18 UTC 2015 [ 1428277638729 ]
        Mark Thomas made changes -
        Workflow jira [ 12958656 ] Default workflow, editable Closed status [ 12995534 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Closed Closed
        1839d 3h 26m 1 Michael Osipov 25/Nov/14 14:30

          People

          • Assignee:
            Unassigned
            Reporter:
            Andre Doherty
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development