maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maxim Frolov (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MEAR-216) Unable to include dependencies of type test-jar
Date Fri, 24 Jul 2015 15:39:05 GMT

    [ https://issues.apache.org/jira/browse/MEAR-216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14640609#comment-14640609
] 

Maxim Frolov commented on MEAR-216:
-----------------------------------

Sorry, the example project showing the error was incorrect.
I have just attached a new project which is the same as the first project but the dependency
in the EAR project to the LIB project is slightly different:


{code:title=<classifier>tests</classifier> works:}
<dependency>
    <groupId>${project.groupId}</groupId>
    <artifactId>test-jar-in-ear-lib</artifactId>
    <version>${project.version}</version>
    <classifier>tests</classifier>
</dependency>
{code}

{code:title=<type>test-jar</type> does not work:}
<dependency>
    <groupId>${project.groupId}</groupId>
    <artifactId>test-jar-in-ear-lib</artifactId>
    <version>${project.version}</version>
    <type>test-jar</type>
</dependency>
{code}


Below is the full log for {{cd lib && mvn -X package}}:
{noformat}
Apache Maven 3.0.5 (r01de14724cdef164cd33c7c8c2fe155faf9602da; 2013-02-19 14:51:28+0100)
Maven home: D:\bin\apache-maven-3.0.5
Java version: 1.8.0_45, vendor: Oracle Corporation
Java home: D:\bin\Java\jdk1.8.0_45\jre
Default locale: de_DE, platform encoding: Cp1252
OS name: "windows 7", version: "6.1", arch: "amd64", family: "dos"
[INFO] Error stacktraces are turned on.
[DEBUG] Reading global settings from D:\bin\apache-maven-3.0.5\conf\settings.xml
[DEBUG] Reading user settings from C:\Users\frol\.m2\settings.xml
[DEBUG] Using local repository at D:\.m2\repository
[DEBUG] Using manager EnhancedLocalRepositoryManager with priority 10 for D:\.m2\repository
[INFO] Scanning for projects...
[DEBUG] Extension realms for project frol:test-jar-in-ear-ear:ear:1.0-SNAPSHOT: (none)
[DEBUG] Looking up lifecyle mappings for packaging ear from ClassRealm[plexus.core, parent:
null]
[DEBUG] === REACTOR BUILD PLAN ================================================
[DEBUG] Project: frol:test-jar-in-ear-ear:ear:1.0-SNAPSHOT
[DEBUG] Tasks:   [package]
[DEBUG] Style:   Regular
[DEBUG] =======================================================================
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building test-jar-in-ear-ear 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources,
generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources,
generate-test-resources, process-test-resources, test-compile, process-test-classes, test,
prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify,
install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources,
generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources,
generate-test-resources, process-test-resources, test-compile, process-test-classes, test,
prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify,
install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources,
generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources,
generate-test-resources, process-test-resources, test-compile, process-test-classes, test,
prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify,
install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources,
generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources,
generate-test-resources, process-test-resources, test-compile, process-test-classes, test,
prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify,
install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] === PROJECT BUILD PLAN ================================================
[DEBUG] Project:       frol:test-jar-in-ear-ear:1.0-SNAPSHOT
[DEBUG] Dependencies (collect): []
[DEBUG] Dependencies (resolve): [test]
[DEBUG] Repositories (dependencies): [artifactory.repo1 (http://example.net:8080/repo1, releases)]
[DEBUG] Repositories (plugins)     : [artifactory.repo1 (http://example.net:8080/repo1, releases)]
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal:          org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
(default-generate-application-xml)
[DEBUG] Style:         Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <defaultLibBundleDir>lib</defaultLibBundleDir>
  <description default-value="${project.description}"/>
  <displayName default-value="${project.artifactId}"/>
  <encoding default-value="UTF-8"/>
  <fileNameMapping>full</fileNameMapping>
  <generateApplicationXml default-value="true"/>
  <generateModuleId default-value="false"/>
  <generatedDescriptorLocation default-value="${project.build.directory}"/>
  <includeLibInApplicationXml default-value="false"/>
  <libraryDirectoryMode default-value="DEFAULT"/>
  <project default-value="${project}"/>
  <tempFolder default-value="${project.build.directory}"/>
  <useBaseVersion>true</useBaseVersion>
  <version default-value="1.3">7</version>
  <workDirectory default-value="${project.build.directory}/${project.build.finalName}"/>
</configuration>
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal:          org.apache.maven.plugins:maven-resources-plugin:2.4.3:resources (default-resources)
[DEBUG] Style:         Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <buildFilters default-value="${project.build.filters}"/>
  <encoding default-value="${project.build.sourceEncoding}">${encoding}</encoding>
  <escapeString default-value="${maven.resources.escapeString}"/>
  <escapeWindowsPaths default-value="true">${maven.resources.escapeWindowsPaths}</escapeWindowsPaths>
  <includeEmptyDirs default-value="false">${maven.resources.includeEmptyDirs}</includeEmptyDirs>
  <outputDirectory default-value="${project.build.outputDirectory}"/>
  <overwrite default-value="false">${maven.resources.overwrite}</overwrite>
  <project default-value="${project}"/>
  <resources default-value="${project.resources}"/>
  <session default-value="${session}"/>
  <useBuildFilters default-value="true"/>
  <useDefaultDelimiters default-value="true"/>
</configuration>
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal:          org.apache.maven.plugins:maven-ear-plugin:2.10:ear (default-ear)
[DEBUG] Style:         Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <defaultLibBundleDir>lib</defaultLibBundleDir>
  <duplicateArtifactsBreakTheBuild default-value="false">${maven.ear.duplicateArtifactsBreakTheBuild}</duplicateArtifactsBreakTheBuild>
  <earSourceDirectory default-value="${basedir}/src/main/application"/>
  <earSourceIncludes default-value="**"/>
  <encoding default-value="UTF-8"/>
  <escapeString>${maven.ear.escapeString}</escapeString>
  <escapedBackslashesInFilePath default-value="false">${maven.ear.escapedBackslashesInFilePath}</escapedBackslashesInFilePath>
  <fileNameMapping>full</fileNameMapping>
  <filtering default-value="false"/>
  <finalName default-value="${project.build.finalName}"/>
  <generatedDescriptorLocation default-value="${project.build.directory}"/>
  <includeLibInApplicationXml default-value="false"/>
  <outputDirectory default-value="${project.build.directory}"/>
  <project default-value="${project}"/>
  <session default-value="${session}"/>
  <skinnyWars default-value="false">${maven.ear.skinnyWars}</skinnyWars>
  <skipClassPathModification default-value="false"/>
  <tempFolder default-value="${project.build.directory}"/>
  <useBaseVersion>true</useBaseVersion>
  <useJvmChmod default-value="true">${maven.ear.useJvmChmod}</useJvmChmod>
  <version default-value="1.3">7</version>
  <workDirectory default-value="${project.build.directory}/${project.build.finalName}"/>
</configuration>
[DEBUG] =======================================================================
[DEBUG] Using mirror artifactory.repo1 (http://example.net:8080/repo1) for central (http://repo.maven.apache.org/maven2).
[DEBUG] Using mirror artifactory.repo1 (http://example.net:8080/repo1) for central (http://repo.maven.apache.org/maven2).
[DEBUG] frol:test-jar-in-ear-ear:ear:1.0-SNAPSHOT
[DEBUG]    frol:test-jar-in-ear-lib:jar:1.0-SNAPSHOT:compile
[DEBUG]    frol:test-jar-in-ear-lib:jar:tests:1.0-SNAPSHOT:compile
[INFO] 
[INFO] --- maven-ear-plugin:2.10:generate-application-xml (default-generate-application-xml)
@ test-jar-in-ear-ear ---
[DEBUG] Created new class realm maven.api
[DEBUG] Importing foreign packages into class realm maven.api
[DEBUG]   Imported: org.apache.maven.cli < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.lifecycle < plexus.core
[DEBUG]   Imported: org.apache.maven.lifecycle < plexus.core
[DEBUG]   Imported: org.apache.maven.repository < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.personality < plexus.core
[DEBUG]   Imported: org.apache.maven.usability < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.configuration < plexus.core
[DEBUG]   Imported: org.sonatype.aether.version < plexus.core
[DEBUG]   Imported: org.sonatype.aether.* < plexus.core
[DEBUG]   Imported: org.sonatype.aether.artifact < plexus.core
[DEBUG]   Imported: org.apache.maven.* < plexus.core
[DEBUG]   Imported: org.apache.maven.project < plexus.core
[DEBUG]   Imported: org.sonatype.aether.repository < plexus.core
[DEBUG]   Imported: org.sonatype.aether.impl < plexus.core
[DEBUG]   Imported: org.apache.maven.exception < plexus.core
[DEBUG]   Imported: org.apache.maven.plugin < plexus.core
[DEBUG]   Imported: org.sonatype.aether.collection < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.* < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.logging < plexus.core
[DEBUG]   Imported: org.apache.maven.profiles < plexus.core
[DEBUG]   Imported: org.sonatype.aether.metadata < plexus.core
[DEBUG]   Imported: org.sonatype.aether.spi < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParserException < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.* < plexus.core
[DEBUG]   Imported: org.sonatype.aether.graph < plexus.core
[DEBUG]   Imported: org.apache.maven.rtinfo < plexus.core
[DEBUG]   Imported: org.sonatype.aether.installation < plexus.core
[DEBUG]   Imported: org.apache.maven.monitor < plexus.core
[DEBUG]   Imported: org.sonatype.aether.transfer < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.context < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.observers < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.resource < plexus.core
[DEBUG]   Imported: org.sonatype.aether.deployment < plexus.core
[DEBUG]   Imported: org.apache.maven.model < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.Xpp3Dom < plexus.core
[DEBUG]   Imported: org.apache.maven.artifact < plexus.core
[DEBUG]   Imported: org.apache.maven.toolchain < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlSerializer < plexus.core
[DEBUG]   Imported: org.apache.maven.settings < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.authorization < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.events < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.authentication < plexus.core
[DEBUG]   Imported: org.apache.maven.reporting < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.repository < plexus.core
[DEBUG]   Imported: org.apache.maven.configuration < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.classworlds < plexus.core
[DEBUG]   Imported: org.codehaus.classworlds < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParser < plexus.core
[DEBUG]   Imported: org.apache.maven.classrealm < plexus.core
[DEBUG]   Imported: org.sonatype.aether.resolution < plexus.core
[DEBUG]   Imported: org.apache.maven.execution < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.proxy < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.container < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.component < plexus.core
[DEBUG] Populating class realm maven.api
[DEBUG] Using mirror artifactory.repo1 (http://example.net:8080/repo1) for central (http://repo.maven.apache.org/maven2).
[DEBUG] org.apache.maven.plugins:maven-ear-plugin:jar:2.10:
[DEBUG]    org.apache.maven:maven-project:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-settings:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-profile:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-model:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-artifact-manager:jar:2.2.1:compile
[DEBUG]          backport-util-concurrent:backport-util-concurrent:jar:3.1:compile
[DEBUG]       org.apache.maven:maven-plugin-registry:jar:2.2.1:compile
[DEBUG]       org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1:compile
[DEBUG]          junit:junit:jar:3.8.1:compile
[DEBUG]    org.apache.maven:maven-plugin-api:jar:2.2.1:compile
[DEBUG]    org.apache.maven:maven-artifact:jar:2.2.1:compile
[DEBUG]    org.apache.maven:maven-core:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.1:compile
[DEBUG]       org.slf4j:slf4j-jdk14:jar:1.5.6:runtime
[DEBUG]          org.slf4j:slf4j-api:jar:1.5.6:runtime
[DEBUG]       org.slf4j:jcl-over-slf4j:jar:1.5.6:runtime
[DEBUG]       org.apache.maven.reporting:maven-reporting-api:jar:2.2.1:compile
[DEBUG]          org.apache.maven.doxia:doxia-sink-api:jar:1.1:compile
[DEBUG]          org.apache.maven.doxia:doxia-logging-api:jar:1.1:compile
[DEBUG]       org.apache.maven:maven-repository-metadata:jar:2.2.1:compile
[DEBUG]       org.apache.maven:maven-error-diagnostics:jar:2.2.1:compile
[DEBUG]       commons-cli:commons-cli:jar:1.2:compile
[DEBUG]       org.apache.maven:maven-plugin-descriptor:jar:2.2.1:compile
[DEBUG]       org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4:compile
[DEBUG]       org.apache.maven:maven-monitor:jar:2.2.1:compile
[DEBUG]       classworlds:classworlds:jar:1.1:compile
[DEBUG]       org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3:compile
[DEBUG]          org.sonatype.plexus:plexus-cipher:jar:1.4:compile
[DEBUG]    org.apache.maven:maven-archiver:jar:2.6:compile
[DEBUG]       org.apache.maven.shared:maven-shared-utils:jar:0.7:compile
[DEBUG]          com.google.code.findbugs:jsr305:jar:2.0.1:compile
[DEBUG]    org.codehaus.plexus:plexus-archiver:jar:2.9:compile
[DEBUG]       org.codehaus.plexus:plexus-io:jar:2.4:compile
[DEBUG]          commons-io:commons-io:jar:2.2:compile
[DEBUG]       org.apache.commons:commons-compress:jar:1.9:compile
[DEBUG]    org.codehaus.plexus:plexus-utils:jar:3.0.20:compile
[DEBUG]    org.apache.maven.shared:maven-filtering:jar:1.3:compile
[DEBUG]       org.sonatype.plexus:plexus-build-api:jar:0.0.4:compile
[DEBUG]    org.codehaus.plexus:plexus-interpolation:jar:1.22:compile
[DEBUG] Created new class realm plugin>org.apache.maven.plugins:maven-ear-plugin:2.10
[DEBUG] Importing foreign packages into class realm plugin>org.apache.maven.plugins:maven-ear-plugin:2.10
[DEBUG]   Imported:  < maven.api
[DEBUG] Populating class realm plugin>org.apache.maven.plugins:maven-ear-plugin:2.10
[DEBUG]   Included: org.apache.maven.plugins:maven-ear-plugin:jar:2.10
[DEBUG]   Included: backport-util-concurrent:backport-util-concurrent:jar:3.1
[DEBUG]   Included: junit:junit:jar:3.8.1
[DEBUG]   Included: org.slf4j:slf4j-jdk14:jar:1.5.6
[DEBUG]   Included: org.slf4j:slf4j-api:jar:1.5.6
[DEBUG]   Included: org.slf4j:jcl-over-slf4j:jar:1.5.6
[DEBUG]   Included: org.apache.maven.reporting:maven-reporting-api:jar:2.2.1
[DEBUG]   Included: org.apache.maven.doxia:doxia-sink-api:jar:1.1
[DEBUG]   Included: org.apache.maven.doxia:doxia-logging-api:jar:1.1
[DEBUG]   Included: commons-cli:commons-cli:jar:1.2
[DEBUG]   Included: org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4
[DEBUG]   Included: org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3
[DEBUG]   Included: org.sonatype.plexus:plexus-cipher:jar:1.4
[DEBUG]   Included: org.apache.maven:maven-archiver:jar:2.6
[DEBUG]   Included: org.apache.maven.shared:maven-shared-utils:jar:0.7
[DEBUG]   Included: com.google.code.findbugs:jsr305:jar:2.0.1
[DEBUG]   Included: org.codehaus.plexus:plexus-archiver:jar:2.9
[DEBUG]   Included: org.codehaus.plexus:plexus-io:jar:2.4
[DEBUG]   Included: commons-io:commons-io:jar:2.2
[DEBUG]   Included: org.apache.commons:commons-compress:jar:1.9
[DEBUG]   Included: org.codehaus.plexus:plexus-utils:jar:3.0.20
[DEBUG]   Included: org.apache.maven.shared:maven-filtering:jar:1.3
[DEBUG]   Included: org.sonatype.plexus:plexus-build-api:jar:0.0.4
[DEBUG]   Included: org.codehaus.plexus:plexus-interpolation:jar:1.22
[DEBUG]   Excluded: org.apache.maven:maven-project:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-settings:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-profile:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-model:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-artifact-manager:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-plugin-registry:jar:2.2.1
[DEBUG]   Excluded: org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1
[DEBUG]   Excluded: org.apache.maven:maven-plugin-api:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-artifact:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-core:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-repository-metadata:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-error-diagnostics:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-plugin-descriptor:jar:2.2.1
[DEBUG]   Excluded: org.apache.maven:maven-monitor:jar:2.2.1
[DEBUG]   Excluded: classworlds:classworlds:jar:1.1
[DEBUG] Configuring mojo org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
from plugin realm ClassRealm[plugin>org.apache.maven.plugins:maven-ear-plugin:2.10, parent:
sun.misc.Launcher$AppClassLoader@4e25154f]
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml'
with basic configurator -->
[DEBUG]   (f) defaultLibBundleDir = lib
[DEBUG]   (f) displayName = test-jar-in-ear-ear
[DEBUG]   (f) encoding = UTF-8
[DEBUG]   (f) fileNameMapping = full
[DEBUG]   (f) generateApplicationXml = true
[DEBUG]   (f) generateModuleId = false
[DEBUG]   (f) generatedDescriptorLocation = D:\tmp\test-jar-in-ear\ear\target
[DEBUG]   (f) includeLibInApplicationXml = false
[DEBUG]   (f) libraryDirectoryMode = DEFAULT
[DEBUG]   (f) project = MavenProject: frol:test-jar-in-ear-ear:1.0-SNAPSHOT @ D:\tmp\test-jar-in-ear\ear\pom.xml
[DEBUG]   (f) tempFolder = D:\tmp\test-jar-in-ear\ear\target
[DEBUG]   (f) useBaseVersion = true
[DEBUG]   (f) version = 7
[DEBUG]   (f) workDirectory = D:\tmp\test-jar-in-ear\ear\target\test-jar-in-ear-ear-1.0-SNAPSHOT
[DEBUG] -- end configuration --
[DEBUG] Resolving artifact type mappings ...
[DEBUG] Initializing JBoss configuration if necessary ...
[DEBUG] Initializing ear execution context
[DEBUG] Resolving ear modules ...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.435s
[INFO] Finished at: Fri Jul 24 17:35:02 CEST 2015
[INFO] Final Memory: 7M/368M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
(default-generate-application-xml) on project test-jar-in-ear-ear: Failed to initialize ear
modules: Unknown artifact type[test-jar] for test-jar-in-ear-lib -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
(default-generate-application-xml) on project test-jar-in-ear-ear: Failed to initialize ear
modules
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
	at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
	at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:260)
	at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:162)
	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
	... 19 more
Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[test-jar]
for test-jar-in-ear-lib
	at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:88)
	at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:250)
	... 22 more
[ERROR] 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following
articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
{noformat}

> Unable to include dependencies of type test-jar
> -----------------------------------------------
>
>                 Key: MEAR-216
>                 URL: https://issues.apache.org/jira/browse/MEAR-216
>             Project: Maven Ear Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.10
>            Reporter: Maxim Frolov
>            Priority: Blocker
>             Fix For: more-investigation
>
>         Attachments: test-jar-in-ear-2.zip, test-jar-in-ear.zip
>
>
> Please implement support for artifacts of type *test-jar*.
> One of the use cases would be to build a test EAR as a mix of production and test JARs
where the test JARs are used to set up the test data used to test the production code.
> Currently including one or more dependencies of type test-jar causes *LifecycleExecutionException*:

> {noformat}
> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
(default-generate-application-xml) on project suite-systemtests-common-ear: Failed to initialize
ear modules: Unknown artifact type[test-jar] for artifact_id -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-ear-plugin:2.10:generate-application-xml
(default-generate-application-xml) on project suite-systemtests-common-ear: Failed to initialize
ear modules
>         at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
>         at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
>         at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
>         at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
>         at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
>         at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
>         at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
>         at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
>         at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
>         at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
>         at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
>         at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:606)
>         at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
>         at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
>         at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
>         at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
>         at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:260)
>         at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:162)
>         at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
>         at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
>         ... 19 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact
type[test-jar] for common-domain-impl
>         at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:88)
>         at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:250)
>         ... 22 more
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message