Maven 2 & 3

Make parsing of settings.xml lenient with respect to unrecognized tags

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 3.0-alpha-3
  • Component/s: Settings
  • Labels:
    None
  • Complexity:
    Intermediate
  • Number of attachments :
    0

Description

Currently, Maven parses the settings.xml in strict mode, making it error out upon occurrence of any tag that it does not understand. This makes co-existence of different Maven versions on the same machine more difficult as a user employing some newly added settings elements can't use the same settings.xml for old Maven versions.

In principle, unrecognized elements don't hurt and can be safely ignored. The only benefit from the strict parsing is to tell the user about potential problems/typos in his settings.xml. This can however also be realized by warnings instead of errors.

Issue Links

Activity

Hide
Benjamin Bentmann added a comment -

Done in r824188.

Show
Benjamin Bentmann added a comment - Done in r824188.
Hide
Paul Benedict added a comment -

If a developer is sharing settings.xml among the same minor versions (2.1, 2.2, etc.), this is reasonable, but if this change then facilitates sharing across major versions (2.1, 3.0), then I think it's not the correct approach. I hope the latter requires an XSD or something to prevent this.

Show
Paul Benedict added a comment - If a developer is sharing settings.xml among the same minor versions (2.1, 2.2, etc.), this is reasonable, but if this change then facilitates sharing across major versions (2.1, 3.0), then I think it's not the correct approach. I hope the latter requires an XSD or something to prevent this.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: