Uploaded image for project: 'Maven EAR Plugin'
  1. Maven EAR Plugin
  2. MEAR-172

Enhance the exception thrown when the EAR plugin can not map an included artifact

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.9
    • None
    • Patch

    Description

      If unknown artifact types are included in the hierarchy of an EAR project's dependency, The ArtifactTypeMappingService will throw an UnknownArtifactTypeException with a message that looks something like "Unknown artifact type[test-jar]". Since the artifact type to be mapped is passed as a string, the getStandardType(final String type) method can't generate a message that includes the artifactId.

      The attached patch includes changes to the EarModuleFactory that catches and rethrows the UnknownArtifactTypeException while appending the artifactId to the exception's message. The changes result in a message that looks something like "Unknown artifact type[test-jar] for jboss-as-ejb3", making debugging a failed EAR build much easier.

      Attachments

        1. patch.txt
          1.0 kB

        Activity

          People

            rfscholte Robert Scholte
            smoyer1 Steve Moyer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: