Maven 2 & 3

ModelUtils.clone doesn't clone plugin entries where inherited == false

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 2.0.10
  • Fix Version/s: 3.0-beta-1
  • Component/s: POM
  • Labels:
    None
  • Complexity:
    Intermediate
  • Testcase included:
    yes
  • Number of attachments :
    1

Description

ModelUtils.clone(..) uses the ModelInheritanceAssembler under the covers, with assembleAsInheritance == true. This is not strictly true, since inheritance semantics are different in some ways from clone semantics.

This becomes an issue where plugins are concerned, especially when the plugin entry in the POM contains inherited == "false", which will lead to the cloning process excluding that plugin from the clone result.

Issue Links

Activity

Hide
John Casey added a comment -

test case (unit test patch for ModelUtilsTest in maven-project)

Show
John Casey added a comment - test case (unit test patch for ModelUtilsTest in maven-project)
Hide
Benjamin Bentmann added a comment -

Might be related to MNG-3539.

Show
Benjamin Bentmann added a comment - Might be related to MNG-3539.
Hide
Benjamin Bentmann added a comment -

ModelUtils is no longer used in 3.x, instead it uses Modello generated clone() methods.

Show
Benjamin Bentmann added a comment - ModelUtils is no longer used in 3.x, instead it uses Modello generated clone() methods.

People

Vote (1)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved: