-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gradle module metadata not published for reactor-core 3.3.5 #2151
Comments
This issue might be caused by the rather old Artifactory plugin: Line 36 in a802238
The publication of Gradle metadata seems to be supported since version 4.11 only (jfrog/build-info#247 jfrog/build-info#265). |
hi @kroka and thanks for reporting! Can you give more details as to how to reproduce the issue, and whether or not it blocks you from depending on reactor at all? I tried to create a Gradle project that imports the BOM and depends on 3.3.5 as a result, both with Gradle 5.x and 6.x, and couldn't get it to complain about the missing deployed metadata. Note that nonetheless it is a publication issue that we'll need to fix one way or another. I'm just wondering if it should trigger a release early than the next planned one, which is end of June. |
Hi, for most users that retrieve the artifacts from Maven Central or JCenter the missing module file is no problem as they will get a HTTP status 404 for it and Gradle will simply ignore it. With Gradle 5 it's also no problem as it does not work with Gradle module metadata. In our projects we use JFrog Artifactory (which kind of proxies the Maven Central repo) that, however, returns 401 instead of 404. While this can be considered as wrong behavior of the Artifactory, the root cause is the invalid POM file / missing module file. Issue in Artifactory: Issue in Gradle We observed the invalid POM files in our projects, too, and solved it by updating the Artifactory plugin. I hope this helps understanding why this is an issue. It's a little thing but has an impact ;) Best regards, |
I think we'll amend the build to avoid generating @bclozel @wilkinsona did you ever come across the case of optional dependencies and found a workaround ? I'm aware that you're moving away from publishing the module metadata too, but that it is due to the lack of support for exclusions |
@kroka since it doesn't seem to affect users that fetch via bintray, the Spring artifactory or Maven Central (as these all give 404), we'll stick to the plan of releasing 3.3.6 in June for now. one workaround I can think about is to checkout the project locally and generate the module metadata: git checkout v3.3.5.RELEASE
./gradlew publishToMavenLocal -x check
cd ~/.m2/repository/io/projectreactor/reactor-core/3.3.5.RELEASE Then you should technically be able to add the The drawback would be that for 3.3.5 you'd inherit strong dependencies instead of optional ones:
|
@simonbasle What's the problem with optional dependencies? We're publishing Gradle module metadata for |
@wilkinsona from what I can see when doing a But of course, that is the result of a customization in a And so, when I try to create a Gradle project that depends on these artifacts with the generated Is that not the case with Spring Boot ? |
Ah, the propdeps plugin. We don't use it in Boot for a few reasons, this being one of them. We have our own OptionalDependenciesPlugin that we use instead. Framework has a copy of it too. It's starting to feel like we should extract it into a spring-gradle-plugins project so it can be shared without copy-paste. |
@simonbasle thank you for the comprehensive feedback! I agree and think that there is no need for an earlier release given that not all users are affected and that the issue we have is rather caused by multiple aspects. |
This commit: - removes propdeps plugin, known to now be problematic - uses a simplified local buildSrc plugin to provide the optional scope Additionally it fixes building kotlin code by ensuring both reactor-core and reactor-test declare an optional dependency to Kotlin stdlib. The custom plugin should result in a Gradle module metadata file that doesn't contain references to optional dependencies. Last but not least, the JFrog Artifactory Gradle plugin has been bumped to 4.15.2, as versions below 4.11 are known to prevent distribution of the .module file to Artifactory.
@kroka facing the same issue, any work around ? |
@santoshkumarcts we do not have a good workaround, but I haven't spent too much time on it (had some struggle with permissions for pushing to the company's Artifactory from my local machine). Right now we stick with Spring Boot 2.2.4 and Spring Cloud Hoxton SR2. A downgrade to Gradle 5.6 should do the job, too, if it does not break your Gradle scripts. |
@santoshkumarcts this seems to work:
with Spring Boot 2.3.0.RELEASE and Spring Cloud Hoxton.SR2 (due to rsocket/rsocket-java#746 downgrading to RC5 did not work on first trial). If you use the Gradle Spring Dependency Management plugin you'll probably have to set the reactor version by a property: https://docs.spring.io/spring-boot/docs/2.3.0.RELEASE/reference/htmlsingle/#dependency-versions-properties |
Current Behavior:
reactor-core 3.3.5 was published with a Gradle module metadata declaration in its POM file (
published-with-gradle-metadata
), however, the corresponding .module file is missing in the Maven Central repository.Expected Behavior:
The text was updated successfully, but these errors were encountered: