Hello,

many thread on this list makes proposal for some changes in the POM.xml
format, to be included in 4.1.0 modelVersion.

Could we use XML namespaces to support progressive enhancements ? Based on
this, proposal for new features could be added to maven, using an
<extension> to support the new schema, without requirement to wait for next
major version to include POM structure changes.

example : considering the recent proposal for profiles enhancements
http://docs.codehaus.org/display/MAVENUSER/Improvements+to+Profile+Activation+Deactivation

<profile>
  <activation>
    <activeByDefault>true</activeByDefault>
  </activation>
  <deactivation>
    <os>
      <name>Windows 98</name>
    </os>
  </deactivation>
</profile>
Could be rewritten :

<extensions>
  <extension xmlns:profile=
http://docs.codehaus.org/display/MAVENUSER/Improvements+to+Profile+Activation+Deactivation
>
    <groupId>org.apache.maven.proposals</groupId>
    <artifactId>profile-enhancements</artifactId>
  </extension>
<extensions>

<profile>
  <activation>
    <activeByDefault>true</activeByDefault>
  </activation>
  <profile:deactivation>
    <profile:os>
      <profile:name>Windows 98</profile:name>
    </profile:os>
  </profile:deactivation>
</profile>
This can be compared with namespace support in Springframework context files
: adding a new custom namespace allow to make the configuration less verbose
or more powerfull, with no requirement to change the base XML model.

Nicolas

Reply via email to