uschindler commented on issue #15246:
URL: https://github.com/apache/lucene/issues/15246#issuecomment-3368575833

   Hi,
   I released forbiddenapis. With the new build infrastructure, integration 
testing was much more complicated and it costed me half an hour until I got the 
new Gradle running with the plugin from `mavenLocal()` (I wanted to do this 
before I publish the plugin in Maven Central and the Gradle Plugin portal). 
Both is now done!
   
   For reference, here are my changes I needed for integration testing:
   
   ```patch
    build-tools/build-infra-shadow/build.gradle | 1 +
    build-tools/build-infra/build.gradle        | 3 ++-
    build.gradle                                | 8 --------
    gradle/libs.versions.toml                   | 2 +-
    settings.gradle                             | 1 +
    5 files changed, 5 insertions(+), 10 deletions(-)
   
   diff --git a/build-tools/build-infra-shadow/build.gradle 
b/build-tools/build-infra-shadow/build.gradle
   index 5b0e3b1a594..f95d3b366e7 100644
   --- a/build-tools/build-infra-shadow/build.gradle
   +++ b/build-tools/build-infra-shadow/build.gradle
   @@ -20,6 +20,7 @@ plugins {
    }
    
    repositories {
   +  mavenLocal()
      mavenCentral()
      gradlePluginPortal()
    }
   diff --git a/build-tools/build-infra/build.gradle 
b/build-tools/build-infra/build.gradle
   index f9b95276852..aaab60c6d97 100644
   --- a/build-tools/build-infra/build.gradle
   +++ b/build-tools/build-infra/build.gradle
   @@ -19,10 +19,11 @@ plugins {
      id "java-gradle-plugin"
      id "groovy-gradle-plugin"
    
   -  alias(deps.plugins.forbiddenapis) apply false
   +  // alias(deps.plugins.forbiddenapis) apply false
    }
    
    repositories {
   +  mavenLocal()
      mavenCentral()
      gradlePluginPortal()
    }
   diff --git a/build.gradle b/build.gradle
   index 638c81f92bc..ae99b51f7ad 100644
   --- a/build.gradle
   +++ b/build.gradle
   @@ -56,11 +56,3 @@ plugins {
    }
    
    description = 'Grandparent project for Apache Lucene Core'
   -
   -// Force forbidden-apis tasks to use JDK 24 signatures until it supports 
JDK 25;
   -// https://github.com/policeman-tools/forbidden-apis/pull/272
   -allprojects {
   -  tasks.withType(CheckForbiddenApis.class).configureEach {
   -    targetCompatibility = "24"
   -  }
   -}
   diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml
   index 8c93b15419c..a1fe418d369 100644
   --- a/gradle/libs.versions.toml
   +++ b/gradle/libs.versions.toml
   @@ -100,7 +100,7 @@ benmanes-versions = 
"com.github.ben-manes.versions:0.52.0"
    carrotsearch-buildopts = "com.carrotsearch.gradle.opts:0.2.0"
    carrotsearch-dependencychecks = 
"com.carrotsearch.gradle.dependencychecks:0.1.0"
    errorprone = "net.ltgt.errorprone:4.3.0"
   -forbiddenapis = "de.thetaphi.forbiddenapis:3.9"
   +forbiddenapis = "de.thetaphi.forbiddenapis:3.10"
    jacocolog = "org.barfuin.gradle.jacocolog:3.1.0"
    randomizedtesting = "com.carrotsearch.gradle.randomizedtesting:0.0.6"
    spotless = "com.diffplug.spotless:7.2.1"
   diff --git a/settings.gradle b/settings.gradle
   index 50480f1479f..5e56496fe6c 100644
   --- a/settings.gradle
   +++ b/settings.gradle
   @@ -17,6 +17,7 @@
    
    pluginManagement {
        repositories {
   +        mavenLocal()
            mavenCentral()
            gradlePluginPortal()
        }
   ```
   
   @dweiss: Do you have a better idea how to test it? Actually it was much 
better than before, because you had that hack that changes the plugin 
identifier to use the Maven Central repository to fetch the plugin. Why was 
this done? I am talking about this:
   
   
https://github.com/apache/lucene/blob/602bfbd9af0ee9027de45c1572527eee6b073841/build-tools/build-infra/build.gradle#L65-L67
   
   Was it not working with Gradle plugin portal as was this done to get 
testinmg done easier -- for me?
   
   If we could add something like above patch directly integrated with some 
system property, it would be cool!


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to