You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add ignorePattern attribute to TrackedProperty for array filtering
Fixes#375 - Maven 4 auto-injects --module-version to compilerArgs during
cache storage but not during validation, causing parameter mismatches.
Changes:
- Add ignorePattern field to TrackedProperty in MDO model
- Implement regex-based filtering in BuildCacheMojosExecutionStrategy
- Filter arrays before comparison (both runtime and cached values)
The ignorePattern attribute allows filtering specific array elements
before comparison, solving the Maven 4 module-version problem while
still detecting legitimate compilerArgs changes.
Users can configure this in maven-build-cache-config.xml:
<reconcile propertyName="compilerArgs" ignorePattern="--module-version"/>
Tested with multi-module JPMS project using Maven 4.0.0-rc-4.
Copy file name to clipboardExpand all lines: src/main/mdo/build-cache-config.mdo
+5Lines changed: 5 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1459,6 +1459,11 @@ under the License.
1459
1459
<name>defaultValue</name>
1460
1460
<type>String</type>
1461
1461
</field>
1462
+
<field xml.attribute="true">
1463
+
<name>ignorePattern</name>
1464
+
<type>String</type>
1465
+
<description>Regular expression pattern to filter out matching values from array/list properties before comparison. Useful for filtering auto-injected values like Maven 4's --module-version</description>
0 commit comments