Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-5465

Solr Contrib "map-reduce" breaks Manifest of all other JAR files by adding a broken Main-Class attribute

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.7
    • 4.7, 4.8, 6.0
    • None
    • None
    • New, Patch Available

    Description

      The addition of the Solr map-reduce contrib created a new "main.class" property, which is used by the jarify task. Currently only the map-reduce plugin actually set this property, soall other generated JAR files contain the following line:

      Main-Class: ${main.class}

      This happens because the ANT property "main.class" is undefined for most modules. Maybe this was added for one of the modules (I assume that the Solr-Morphline JARs use this attribute?). We should add some if/then/else structure to the <jarify/> task that only sets this property, if it is actually defined. Otherwise remove it (I think ANT does this automatically if its empty, means string-empty, have to try out)

      This leads to an error if the file is double-clicked or started via java -jar:

      C:\Users\Uwe Schindler\Desktop>java -jar lucene-core-4.7.0.jar
      Fehler: Hauptklasse ${main.class} konnte nicht gefunden oder geladen werden
      

      I opened this issue in LUCENE, because jar files from LUCENE and SOLR are affected.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            sarowe Steven Rowe
            uschindler Uwe Schindler
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment