gnodet-bot commented on code in PR #14193:
URL: https://github.com/apache/maven/pull/14193#discussion_r4746717193


##########
impl/maven-core/src/main/java/org/apache/maven/lifecycle/internal/concurrent/BuildStep.java:
##########
@@ -157,6 +162,10 @@ public int hashCode() {
         return Objects.hash(project, name);
     }
 
+    String stepId() {
+        return project.getGroupId() + ":" + project.getArtifactId() + ":" + 
project.getVersion() + "/" + name;
+    }

Review Comment:
   ⚠️ **Cache miss on version bump**: `stepId()` includes the POM version 
(`g:a:v/name`), which means all cached timings become orphans whenever the 
version changes — SNAPSHOT bump, release cut, or any `<version>` edit. The 
first build after any version change falls back to depth-based scheduling 
silently.
   
   Since step durations are a property of the build graph structure (not the 
version), dropping the version makes the cache durable across releases:
   
   ```suggestion
       String stepId() {
           return project.getGroupId() + ":" + project.getArtifactId() + "/" + 
name;
       }
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to