This message was deleted.
# community-support
s
This message was deleted.
c
Spring Boot is very heavyweight and not intended to be used at build time. The Spring Boot gradle plugin is for building Spring Boot projects, not importing that into your build script (it doesn’t belong there). While it may be possible to add it (it’s Gradle / JVM, any classes can be loaded) its a code smell worth revisiting the approach.
d
I get it. What I'm trying to implement is this https://gradle-community.slack.com/archives/CAHSN3LDN/p1686575753063799.
c
not sure how extensive the desired ‘shared’ configuration would be, but would suggest that some (if not all) of that should not be shared. For example, DB credentials to upgrade a database via Liquibase should have greater permissions (create,drop table, index etc) that the app would. And those property files are only one means of configuring a SB app; properties can come from elsewhere at runtime (any PropertySource instance).
d
Sure, but what about the case where people use liquibase+spring boot, instead of the gradle plugin? Those settings would already be in those properties files. I'd just like to have the option to use both.
v
Even though I tend to generally agree with Chris, to answer your inital question, you either need to add a dependency on what you want to use in the build script via
buildscript { dependencies { classpath(...) } }
, or maybe better you move that logic to a custom plugin or task that you develop in
buildSrc
or an included build and then there declare as normal dependency.
d
Thanks, I'll look into it. Maybe I even get to convince the maintainers of Spring Boot to make something proper for this use case.
👌 1