Using the develocity plugin with injection seems t...
# develocity
i
Using the develocity plugin with injection seems to disable configuration caching;
Copy code
Calculating task graph as configuration cache cannot be reused because system property 'com.gradle.develocity.ide.plugin.port' has changed.
w
Thank you for reporting. Can you check the configuration cache report? You will probably have a Gradle plugin that reads all your system properties at configuration time, essentially making them a configuration cache input. E.g. Quarkus plugin is one of the plugins that does this (and shouldn’t).
i
The build doesn't generate a configuration cache report (or at least it's not displayed at the end of the execution). It does generate a problems report, but it doesn't contain anything related to the configuration cache.
w
You can find configuration cache reports for all builds (even those that don’t advertise them), in
build/reports/configuration-cache/<unique-hash>
. The last one should be in the newest directory in there.
i
I have it, what should I look for?
w
Check out
Build configuration inputs
->
system property
->
com.gradle.develocity.ide.plugin.port
and then see where it is being read.
i
plugin 'de.infix.testBalloon'
I know the maintainer, I'll ping them, is there a TL;DR or documentation on what they should look out for?
v
Well, they should not read all system properties 🙂
i
Is it just replacing
System.getenv()
by
System.getenv("foo")
?
i
Ah
v
They need to use
providers.systemPropertiesPrefixedBy
or a
ValueSource
to read all and filter out the relevant ones.
👍 1
i
Ah they already have an issue for it 😅 → https://github.com/infix-de/testBalloon/issues/20
v
Sorry @wolfs should have let you answer and not try to take-over 😄
w
The issue seems to be talking about the plugin reading all the env vars, though that is essentially the same problem.
👆 1
@Ivan CLOVIS Canet Can you comment on the issue that they also should fix reading all the system properties?
i
Yep, on it
thank you 1
v
And that there are ways to do it properly, seems the issue just blames other issues and missing features, while they could indeed to it better. 🙂
They maybe are just not aware of how
Yeah,
providers.systemPropertiesPrefixedBy
seems to be exactly what they need, but I would've had no idea where to look for such a feature
i
Thanks! That page is a monster, I've read multiple times already and I still find things in it that I didn't know about…
👍 1
w
What helps is searching on that page for the problem you want to solve.
v
Great power comes with great responsibility 😄
🙌 1