[ 
https://issues.apache.org/jira/browse/MJAVADOC-513?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Scholte closed MJAVADOC-513.
-----------------------------------
       Resolution: Fixed
         Assignee: Robert Scholte
    Fix Version/s: 3.0.2

I've changed the HashMap into a LinkedHashMap in 
[06407e349f578629c15ab2f53edb23d64cb6b2ae|https://gitbox.apache.org/repos/asf?p=maven-javadoc-plugin.git;a=commit;h=06407e349f578629c15ab2f53edb23d64cb6b2ae]

For the additionalDependencies I need to investigate it a bit more. If you 
think that is still required, please create a new issue with a minimal project 
to demonstrate why you need it.

> Aggregate: make order of classpath entries predictable
> ------------------------------------------------------
>
>                 Key: MJAVADOC-513
>                 URL: https://issues.apache.org/jira/browse/MJAVADOC-513
>             Project: Maven Javadoc Plugin
>          Issue Type: Improvement
>          Components: javadoc
>    Affects Versions: 3.0.0
>            Reporter: Konrad Windszus
>            Assignee: Robert Scholte
>            Priority: Major
>             Fix For: 3.0.2
>
>
> The order of the classpath entries being generated in 
> {{AbstractJavadocMojo.getPathElements()}} 
> (https://github.com/apache/maven-javadoc-plugin/blob/12dbbde29cf6277ca311cb8afffdf02dbfe0c9b4/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java#L2601)
>  is internally relying on a {{HashMap}} for the compile time artifacts. That 
> is an issue if the classpath is not 100% clean (i.e. the same package is 
> exported by multiple artifacts) because then the success depends on the order 
> which is not predicable for regular {{HashMaps}}. Unclean classpaths are 
> unfortunately pretty common in reality. 
> To make builds more reliable please use a {{LinkedHashMap}} instead as that 
> will keep the insertion order. 
> Also since elements being returned first have a higher precedence the ones 
> being maintained via {{additionalDependencies}} should be added first (after 
> the module's target directory but before the compileArtifacts) to allow to 
> enforce usage of a certain module for dedicated classes.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to