[
https://issues.apache.org/jira/browse/MTOMCAT-240?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13782909#comment-13782909
]
Hudson commented on MTOMCAT-240:
--------------------------------
SUCCESS: Integrated in TomcatMavenPlugin-mvn3.x #256 (See
[https://builds.apache.org/job/TomcatMavenPlugin-mvn3.x/256/])
[MTOMCAT-240] Artifacts with same artifactID but different groupID are skipped
Submitted by Petar Tahchiev (olamy:
http://svn.apache.org/viewvc/?view=rev&rev=1528073)
*
/tomcat/maven-plugin/trunk/common-tomcat-maven-plugin/src/main/java/org/apache/tomcat/maven/common/run/DefaultClassLoaderEntriesCalculator.java
> Artifacts with same artifactID but different groupID are skipped
> ----------------------------------------------------------------
>
> Key: MTOMCAT-240
> URL: https://issues.apache.org/jira/browse/MTOMCAT-240
> Project: Apache Tomcat Maven Plugin
> Issue Type: Bug
> Components: commons-lib
> Affects Versions: 2.1
> Environment: all
> Reporter: Petar Tahchiev
> Assignee: Olivier Lamy (*$^¨%`£)
> Fix For: 2.2
>
> Attachments: MTOMCAT-240.patch
>
>
> Hi guys,
> I have the following situation: my classpath includes the following artifacts:
> 1) artifactA in group com.mygroup
> 2) artifactA in group com.myothergroup.
> Looking in DefaultClassLoaderEntriesCalculator.java on line 120 we see the
> following:
> {code}
> String fileName = artifact.getFile().getName();
> if ( !fileInClassLoaderEntries.contains( fileName ) )
> {
> // add the artifact to the classpath
> }
> {code}
> So in my case both artifacts are resolved as artifactA-1.0-SNAPSHOT.jar so
> the second one gets omitted. I have chaged to code to simply include the
> categoryID like this:
> {code}
> String fileName = artifact.getGroupId() + "-" +
> artifact.getFile().getName();
> if ( !fileInClassLoaderEntries.contains( fileName ) )
> {
> //add to classpath
> }
> {code}
> and it works like a charm.
> You can find the patch attached. Please review it and apply.
--
This message was sent by Atlassian JIRA
(v6.1#6144)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]