You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Tom Bollwitt (JIRA)" <ji...@codehaus.org> on 2006/08/30 18:53:50 UTC
[jira] Created: (MPEAR-46) Unknown artifact type[java-source]
Unknown artifact type[java-source]
-----------------------------------
Key: MPEAR-46
URL: http://jira.codehaus.org/browse/MPEAR-46
Project: maven-ear-plugin
Issue Type: Bug
Environment: Windows
Eclipse 3.1
Reporter: Tom Bollwitt
Priority: Trivial
When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
<dependency>
<groupId>mygroup</groupId>
<artifactId>artifact2</artifactId>
<version>1.0</version>
<type>java-source</type>
</dependency>
When running 'package' or ear:ear I am getting the following error:
[INFO] [ear:generate-application-xml]
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Failed to initialize ear modules
Embedded error: Unknown artifact type[java-source]
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
... 16 more
Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
... 19 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2 seconds
[INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
[INFO] Final Memory: 4M/7M
I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MPEAR-46) Unknown artifact type[java-source]
Posted by "Kannan Kesavan (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MPEAR-46?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=178865#action_178865 ]
Kannan Kesavan commented on MPEAR-46:
-------------------------------------
Hi,
We are also facing same issue in maven-ear-plugin. In our project, one of our transitive dependency using ".so" files. In that project, they didn't specify any scope for ".so" files. Also it is not possible for us to give scope (entirely different project, and it is not in our hands to change/give scope). Finally we build our ear module, it is throwing unknown artifact types[so].
Could you please let me know when it will be fixed?
Thanks,
Kannan
> Unknown artifact type[java-source]
> -----------------------------------
>
> Key: MPEAR-46
> URL: http://jira.codehaus.org/browse/MPEAR-46
> Project: Maven 1.x Ear Plugin
> Issue Type: Bug
> Environment: Windows
> Eclipse 3.1
> Reporter: Tom Bollwitt
> Priority: Trivial
> Fix For: 1.9.1
>
>
> When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
> <dependency>
> <groupId>mygroup</groupId>
> <artifactId>artifact2</artifactId>
> <version>1.0</version>
> <type>java-source</type>
> </dependency>
> When running 'package' or ear:ear I am getting the following error:
> [INFO] [ear:generate-application-xml]
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ------------------------------------------------------------------------
> [INFO] Failed to initialize ear modules
> Embedded error: Unknown artifact type[java-source]
> [INFO] ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
> at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
> at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
> ... 16 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
> at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
> at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
> ... 19 more
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
> [INFO] Final Memory: 4M/7M
> I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MPEAR-46) Unknown artifact type[java-source]
Posted by "Brian Topping (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MPEAR-46?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108962 ]
Brian Topping commented on MPEAR-46:
------------------------------------
Actually, it turns out this is the correct behavior. If your ear has a dependency that is scoped appropriately, it should be included. <scope>provided</scope> would also work around having the dependency without including it.
On the other hand, if you do want to include it, the way to do so is documented at http://maven.apache.org/plugins/maven-ear-plugin/introduction.html. In your case, you would want to use:
{code}
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<configuration>
<artifactTypeMappings>
<artifactTypeMapping type="java-source" mapping="jar"/>
</artifactTypeMappings>
</configuration>
</plugin>
</plugins>
</build>
{code}
> Unknown artifact type[java-source]
> -----------------------------------
>
> Key: MPEAR-46
> URL: http://jira.codehaus.org/browse/MPEAR-46
> Project: Maven 1.x Ear Plugin
> Issue Type: Bug
> Environment: Windows
> Eclipse 3.1
> Reporter: Tom Bollwitt
> Priority: Trivial
> Fix For: 1.9.1
>
>
> When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
> <dependency>
> <groupId>mygroup</groupId>
> <artifactId>artifact2</artifactId>
> <version>1.0</version>
> <type>java-source</type>
> </dependency>
> When running 'package' or ear:ear I am getting the following error:
> [INFO] [ear:generate-application-xml]
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ------------------------------------------------------------------------
> [INFO] Failed to initialize ear modules
> Embedded error: Unknown artifact type[java-source]
> [INFO] ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
> at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
> at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
> ... 16 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
> at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
> at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
> ... 19 more
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
> [INFO] Final Memory: 4M/7M
> I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MPEAR-46) Unknown artifact type[java-source]
Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MPEAR-46?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108986 ]
Lukas Theussl commented on MPEAR-46:
------------------------------------
This issue was opened for the Maven 1 EAR plugin, please copy it over to http://jira.codehaus.org/browse/MEAR if you see the same in m2.
> Unknown artifact type[java-source]
> -----------------------------------
>
> Key: MPEAR-46
> URL: http://jira.codehaus.org/browse/MPEAR-46
> Project: Maven 1.x Ear Plugin
> Issue Type: Bug
> Environment: Windows
> Eclipse 3.1
> Reporter: Tom Bollwitt
> Priority: Trivial
> Fix For: 1.9.1
>
>
> When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
> <dependency>
> <groupId>mygroup</groupId>
> <artifactId>artifact2</artifactId>
> <version>1.0</version>
> <type>java-source</type>
> </dependency>
> When running 'package' or ear:ear I am getting the following error:
> [INFO] [ear:generate-application-xml]
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ------------------------------------------------------------------------
> [INFO] Failed to initialize ear modules
> Embedded error: Unknown artifact type[java-source]
> [INFO] ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
> at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
> at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
> ... 16 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
> at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
> at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
> ... 19 more
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
> [INFO] Final Memory: 4M/7M
> I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Updated: (MPEAR-46) Unknown artifact type[java-source]
Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MPEAR-46?page=all ]
Lukas Theussl updated MPEAR-46:
-------------------------------
Fix Version/s: 1.9.1
> Unknown artifact type[java-source]
> -----------------------------------
>
> Key: MPEAR-46
> URL: http://jira.codehaus.org/browse/MPEAR-46
> Project: maven-ear-plugin
> Issue Type: Bug
> Environment: Windows
> Eclipse 3.1
> Reporter: Tom Bollwitt
> Priority: Trivial
> Fix For: 1.9.1
>
>
> When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
> <dependency>
> <groupId>mygroup</groupId>
> <artifactId>artifact2</artifactId>
> <version>1.0</version>
> <type>java-source</type>
> </dependency>
> When running 'package' or ear:ear I am getting the following error:
> [INFO] [ear:generate-application-xml]
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ------------------------------------------------------------------------
> [INFO] Failed to initialize ear modules
> Embedded error: Unknown artifact type[java-source]
> [INFO] ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
> at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
> at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
> ... 16 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
> at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
> at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
> ... 19 more
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
> [INFO] Final Memory: 4M/7M
> I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Commented: (MPEAR-46) Unknown artifact type[java-source]
Posted by "Brian Topping (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MPEAR-46?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_108914 ]
Brian Topping commented on MPEAR-46:
------------------------------------
I've run into this issue now as well, in 2.0.7. One of my projects generates an artifact of type "template", which is depended upon by several others.
Oddly, this worked just fine on one machine, but not another. Will report more as I get it.
> Unknown artifact type[java-source]
> -----------------------------------
>
> Key: MPEAR-46
> URL: http://jira.codehaus.org/browse/MPEAR-46
> Project: Maven 1.x Ear Plugin
> Issue Type: Bug
> Environment: Windows
> Eclipse 3.1
> Reporter: Tom Bollwitt
> Priority: Trivial
> Fix For: 1.9.1
>
>
> When a POM (parent or dependency) includes java source jar dependencies they are not ignored and an error is thrown.
> <dependency>
> <groupId>mygroup</groupId>
> <artifactId>artifact2</artifactId>
> <version>1.0</version>
> <type>java-source</type>
> </dependency>
> When running 'package' or ear:ear I am getting the following error:
> [INFO] [ear:generate-application-xml]
> [INFO] ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ------------------------------------------------------------------------
> [INFO] Failed to initialize ear modules
> Embedded error: Unknown artifact type[java-source]
> [INFO] ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to initialize ear modules
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:475)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:454)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to initialize ear modules
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:151)
> at org.apache.maven.plugin.ear.GenerateApplicationXmlMojo.execute(GenerateApplicationXmlMojo.java:110)
> at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
> at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
> ... 16 more
> Caused by: org.apache.maven.plugin.ear.UnknownArtifactTypeException: Unknown artifact type[java-source]
> at org.apache.maven.plugin.ear.ArtifactTypeMappingService.getStandardType(ArtifactTypeMappingService.java:153)
> at org.apache.maven.plugin.ear.EarModuleFactory.newEarModule(EarModuleFactory.java:60)
> at org.apache.maven.plugin.ear.AbstractEarMojo.execute(AbstractEarMojo.java:144)
> ... 19 more
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Wed Aug 30 11:49:59 CDT 2006
> [INFO] Final Memory: 4M/7M
> I added <scope>test</scope> to the java-source dependency and was able to work around this issue. The scope is missleading and therefore the desired behavior would be to not require scoping the java-source dependency.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira