You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by "Kariem Hussein (JIRA)" <ji...@apache.org> on 2015/04/28 14:55:06 UTC

[jira] [Comment Edited] (TOMEE-1566) [tomee-maven-plugin] Allow for name customizations for .rar apps

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

Kariem Hussein edited comment on TOMEE-1566 at 4/28/15 12:54 PM:
-----------------------------------------------------------------

After a quick look through the sources I found the following in [AbstractTomEEMojo:566|https://git1-us-west.apache.org/repos/asf?p=tomee.git;a=blob;f=maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java;h=0c30cc1216cd51eca54b53e5350adf3bd12e1f2a;hb=refs/heads/tomee-1.7.x#l563]:

{code:java}
if (!extractedName.endsWith(".jar") && !extractedName.endsWith(".war") && !extractedName.endsWith(".ear")) {
  extractedName = extractedName + "." + defaultType;
}
{code}

For apps, this section is called with ".jar" as default type, so this explains the resulting filename.

I have attached the corresponding (very trivial) patch: [^tomee-1566-include-rar-in-rename.patch]

Please have a look.


was (Author: kariem):
After a quick look through the sources I found the following in [AbstractTomEEMojo:566|https://git1-us-west.apache.org/repos/asf?p=tomee.git;a=blob;f=maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java;h=0c30cc1216cd51eca54b53e5350adf3bd12e1f2a;hb=refs/heads/tomee-1.7.x#l563]:

{code:java}
if (!extractedName.endsWith(".jar") && !extractedName.endsWith(".war") && !extractedName.endsWith(".ear")) {
  extractedName = extractedName + "." + defaultType;
}
{code}

For apps, this section is called with ".jar" as default type, so this explains the resulting filename.

I have attached the corresponding (very trivial) patch: !tomee-1566-include-rar-in-rename.patch!

Please have a look.

> [tomee-maven-plugin] Allow for name customizations for .rar apps
> ----------------------------------------------------------------
>
>                 Key: TOMEE-1566
>                 URL: https://issues.apache.org/jira/browse/TOMEE-1566
>             Project: TomEE
>          Issue Type: Improvement
>          Components: TomEE Maven Plugin
>    Affects Versions: 1.7.2
>            Reporter: Kariem Hussein
>            Assignee: Romain Manni-Bucau
>             Fix For: 2.0.0-Milestone-1
>
>         Attachments: tomee-1566-include-rar-in-rename.patch
>
>
> I want to deploy a maven dependency {{com.something:something-special:1.0.0:rar}} as {{something-else.rar}} via the {{?name}} customization.
> According to the (sparse) docs it should work like this
> {code:xml}
> <plugin>
>   <groupId>org.apache.openejb.maven</groupId>
>   <artifactId>tomee-maven-plugin</artifactId>
>   <configuration>
>     ...
>     <apps>
>       <app>com.something:something-special:1.0.0:rar?name=something-else.rar</app>
>     </apps>
>     ...
>   </configuration>
> </plugin>
> {code}
> Unfortunately, the resulting file name is {{something-else.rar.jar}}.



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