nebula-dependency-recommender-plugin icon indicating copy to clipboard operation
nebula-dependency-recommender-plugin copied to clipboard

Add Example(s) of Nebula -> Gradle Feature Migration

Open romeara opened this issue 6 years ago • 5 comments

Given the current documentation of the README that this plug-in is deprecated in favor of the Gradle BOM feature, it would be helpful to have an "example migration" provided - the documentation for the Gradle feature is somewhat scattered and unclear, with the BOM stuff being referenced as able to achieve a variety of things. This is making it difficult to clearly figure out how one would achieve setting up a file to define versions in the same way nebula allows via this feature, among the Gradle feature's other uses.

romeara avatar Feb 08 '19 22:02 romeara

Hi @romeara we are still working on the feature so this will be added later. The plan is to completely migrate to Gradle based implementation. If you are using maven BOM based recommendation the change should be transparent for you. If you are using other types of recommendation (e.g. a map directly in your build file) they won't be supported anymore. This will be documented with a release which will remove those features. I hope this helps.

chali avatar Feb 11 '19 17:02 chali

It does, thank you! Completely understandable that examples are on the back burner until actually needed :)

Also, just to make sure it's clear for when the time comes, what would be very useful is "here's how to take your current dependency-recommender configuration and convert it to the Gradle based implementation".

Thanks!

romeara avatar Feb 13 '19 01:02 romeara

We are using the neat future https://github.com/nebula-plugins/nebula-dependency-recommender-plugin/wiki/Custom-Provider feature of the nebula-dependency-recommender-plugin. And depend heavily on it. I don't quite see yet how Gradle supports this.

chhex avatar Sep 11 '19 11:09 chhex

Just saw, implementing a ComponentMetadataRule is probably the way to go : https://docs.gradle.org/current/userguide/customizing_dependency_resolution_behavior.html?

chhex avatar Sep 11 '19 11:09 chhex

Actually that is a good point I haven't made clear. Unfortunately, not every feature of this plugin will have its counterpart in Gradle itself. We haven't discussed or planned what will happen with those. The feature which is the most prominent to us is this one https://github.com/nebula-plugins/nebula-dependency-recommender-plugin/wiki/Maven-BOM-Provider here is the Gradle equivalent feature https://docs.gradle.org/5.6.2/userguide/managing_transitive_dependencies.html#sec:bom_import

chali avatar Sep 11 '19 23:09 chali