But that is not the "completely arbitrary" you described earlier. I think that "completely arbitrary" and "not correct" are very different things.
-----Original Message----- From: David Jackman [mailto:[EMAIL PROTECTED] Sent: Thursday, November 10, 2005 13:30 To: Maven Users List Subject: RE: [m2] Inherited plugin execution order I didn't miss that. The problem is that the natural ordering of the keys is not the correct order. The current ordering will be alphabetically by plugin groupId and artifactId. What it should be is the ordering as listed in the parent POM followed by the ordering as listed in the project POM (with any of the project-specified plugins removed if they are covered by the parent's list). ..David.. -----Original Message----- From: Allison, Bob [mailto:[EMAIL PROTECTED] Sent: Thursday, November 10, 2005 10:57 AM To: Maven Users List Subject: RE: [m2] Inherited plugin execution order Since you missed this in the SortedMap definition (which TreeMap implements): "A map that further guarantees that it will be in ascending key order, sorted according to the natural ordering of its keys (see the Comparable interface), or by a comparator provided at sorted map creation time. This order is reflected when iterating over the sorted map's collection views (returned by the entrySet, keySet and values methods)." This means that the values retrieved ARE in the order defined by the keys. -----Original Message----- From: David Jackman [mailto:[EMAIL PROTECTED] Sent: Thursday, November 10, 2005 12:34 To: Maven Users List Subject: RE: [m2] Inherited plugin execution order Actually, it appears even the docs aren't correct. I moved the javadoc plugin to the parent and left my plugin in the subproject, and it still doesn't work. It only works if nothing is in the parent and both plugins are listed (with the javadoc plugin first) in the subproject POM. Upon closer inspection, it appears that the order will be as listed if there aren't any plugins inherited from the parent. If inheritance is involved, then the ordering is arbitrary. Looking at org.apache.maven.project.ModelUtils, it looks like the plugin lists are merged using a TreeMap, which sorts the entries by the "natural ordering of the keys". Since at the end of the merge process we take the values list, this will be completely arbitrary. I wrote a bug on this (MNG-1499). ..David.. -----Original Message----- From: David Jackman [mailto:[EMAIL PROTECTED] Sent: Thursday, November 10, 2005 9:33 AM To: Maven Users List Subject: [m2] Inherited plugin execution order According to the docs (http://maven.apache.org/guides/introduction/introduction-to-the-lifecyc le.html): " When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first." This much seems to be true. However, how can I determine/specify the order that inherited executions run? I thought it would be the order specified in the parent POM, but that doesn't seem to be the case. My plugin needs to run after the javadoc plugin (but really ought to be in the same phase), but I can't seem to make this happen for inherited projects. ..David.. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
