jdaugherty commented on code in PR #16644:
URL: https://github.com/apache/grails-core/pull/16644#discussion_r4264945654
##########
build-logic/plugins/src/main/groovy/org/apache/grails/buildsrc/GrailsDependencyValidatorPlugin.groovy:
##########
@@ -94,50 +101,42 @@ class GrailsDependencyValidatorPlugin implements
Plugin<Project> {
*
* <p>Inspecting the dependency graph needs the project, so it happens
while the task's inputs are
* computed - after the build scripts have run, and before any task
executes - rather than from a
- * {@code doLast} block. The task itself then only compares the two
version maps it was given.</p>
+ * {@code doLast} block. The BOM is detected and its configurations found,
resolved and walked once,
+ * in a memoized provider of a {@link BomDependencyGraph}; every task
input is mapped off that one
+ * result. The task itself then only compares the values it was given.</p>
*
- * <p>Every provider short-circuits when the project opts out, so a
skipped project never pays for
+ * <p>The provider short-circuits when the project opts out, so a skipped
project never pays for
* the resolution or the BOM probing.</p>
*/
private static void registerDependencyVersionValidation(Project project) {
- Provider<String> bomPath = project.provider {
+ Provider<BomDependencyGraph> graph = project.provider({
Review Comment:
We were reading the bom graph 4 times in our build, which meant the
configuration cache couldn't cache it. By modifying the inputs to this, we're
now only reading this once, which improved the configuration cache time.
--
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]