Quarkus: Gradle plugin does not work with plugins DSL

Created on 5 Nov 2019  路  8Comments  路  Source: quarkusio/quarkus

Describe the bug
As described in https://plugins.gradle.org/plugin/io.quarkus the preferred way to include the Quarkus Gradle plugin should be

plugins {
    id "io.quarkus" version "0.28.0"
}

Expected behavior
The Gradle plugins API should work for Quarkus.

Actual behavior

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring root project 'extension-registry'.
> Could not resolve all artifacts for configuration ':classpath'.
   > Could not find org.gradle:gradle-tooling-api:5.5.1.
     Searched in the following locations:
       - https://plugins.gradle.org/m2/org/gradle/gradle-tooling-api/5.5.1/gradle-tooling-api-5.5.1.pom
     Required by:
         project : > io.quarkus:io.quarkus.gradle.plugin:0.28.0 > gradle.plugin.io.quarkus:quarkus-gradle-plugin:0.28.0

It works only when using the legacy plugin syntax.

To Reproduce
Steps to reproduce the behavior:

  1. Create a Gradle project.
  2. Add the "io.quarkus" plugin as described above.
  3. ./gradlew build

Environment

  • Output of uname -a:
Linux ws-b83fff23-645e-4022-baec-7cf6c437f8cc 4.14.145+ #1 SMP Tue Oct 8 03:03:11 PDT 2019 x86_64 x86_64 x86_64 GNU/Linux
  • Output of java -version:
openjdk version "11.0.2" 2019-01-15 LTS
OpenJDK Runtime Environment Zulu11.29+3-CA (build 11.0.2+7-LTS)
OpenJDK 64-Bit Server VM Zulu11.29+3-CA (build 11.0.2+7-LTS, mixed mode)
  • Quarkus version: 0.28.0
  • Gradle version: 5.6.3
aregradle kinbug triagout-of-date

All 8 comments

This returns a 404: https://plugins.gradle.org/m2/org/gradle/gradle-tooling-api/5.5.1/gradle-tooling-api-5.5.1.pom .

I don't know if the issue is us using it or the file being unavailable.

/cc @geoand @gastaldi

Can you try with 0.28.1 please?

I may be wrong but the apply plugin: 'io.quarkus' is necessary to support calls to nativeTestImplementation in the dependencies{} section?

Adding this issue to #5101

@geoand same problem with 0.28.1.

Thanks for checking @spoenemann

I think this issue should be closed.
I use the new syntax with Gradle 6.1.1/Quarkus 1.2.0.Final without problems.

@gastaldi OK to close?

Was this page helpful?
0 / 5 - 0 ratings