jcenter is being shut down - this impacts gradle plugin portal where smithy-gradle-plugin is hosted
DanielBauman88 opened this issue · 5 comments
https://blog.gradle.org/jcenter-shutdown
I'm not sure I understand it correctly, but I think the fix is to move smithy-gradle-plugin to MavenCentral.
Otherwise, we will keep running into intermitten cases of
> Unable to load Maven meta-data from https://plugins.gradle.org/m2/software/amazon/smithy/smithy-aws-cloudformation-traits/maven-metadata.xml.
> Could not HEAD 'https://jcenter.bintray.com/software/amazon/smithy/smithy-aws-cloudformation-traits/maven-metadata.xml'.
> Read timed out
because we have to use gradlePluginPortal for smithy-gradle-plugin.
Is there a different fix we can apply to prevent these issues or can smithy-gradle-plugin be moved to MavenCentral?
We're looking into this. We don't use jcenter directly, and for some reason jcenter, seems to still be used by gradlePluginPortal. In the meantime, I think passing --offline
to Gradle when building will let you use local dependencies if you already have locally cached versions of them.
This doesn't seem to be a Smithy issue, but rather a gradle issue in general. It seems to occur when you are using any gradle plugins, and have dependencies with version ranges. What plugins those are and which dependencies don't seem to matter. Pinning to specific versions seems to be a temporary workaround.
The following sample gradle setup exercises the issue:
build.gradle
:
buildscript {
repositories {
mavenLocal()
mavenCentral()
}
dependencies {
"classpath"("com.fasterxml.jackson.core:jackson-databind:[2.0.0,2.1.0[")
}
}
plugins {
id("com.github.spotbugs") version "4.7.1"
}
repositories {
mavenLocal()
mavenCentral()
}
settings.gradle
:
pluginManagement {
repositories {
gradlePluginPortal()
}
}
rootProject.name = 'gradleissue'
We're still investigating the issue to see if there's some better configuration to use. In the meantime https://status.gradle.com is showing issues too, including when this issue was opened last week.
It appears that the fix here is to add the artifact to MavenCentral so there are multiple locations to pull from in case of another gradle plugin portal issue.
Release process has been updated to include release of a Maven artifact. Once I confirm that artifact has been published in the next release I will close this issue.
Smithy gradle plugin artifacts are now available on maven as well. Closing.