Uploaded image for project: 'Maven Shade Plugin'
  1. Maven Shade Plugin
  2. MSHADE-153

Relocating all classes packages preappends that pattern to date strings

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Auto Closed
    • 2.0
    • None
    • None
    • Intelij- IDEA

    Description

      When relocating all all classes for a given project, I ran into issues with date stings. The relocations were formatted in the pom as:

      <relocation>
      <!-<pattern></pattern>->
      <shadedPattern>apitests.</shadedPattern>
      <relocation>

      The original idea for relocating everything in this way was to avoid non-compatible versions when this project is imported, and it worked once I excluded all java files from relocation.

      However it seems that shade was pre-appending the strings "apitest." to strings inside class files that had nothing to do with the location of classes. Specifically when formatting a "com.fasterxml.jackson.databind.util.StdDateFormat" which should have been "yyyy-MM-dd'T'HH:mm:ss.SSSZ" it threw an illegal argument exception when trying to parse the date string "apitests.yyyy-MM-dd'T'HH:mm:ss.SSSZ" It would appear that shade pre-appended "apitests." to multiple strings which follow a very similar format to strings which like locations of files.

      Edit: submitted before I was read edit completes the issue

      Attachments

        Activity

          People

            Unassigned Unassigned
            zzkid4vzz sam schumer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: