-
Notifications
You must be signed in to change notification settings - Fork 33
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
Enabled Caching for LombokConfig Task #525
Conversation
Codecov Report
@@ Coverage Diff @@
## master #525 +/- ##
============================================
+ Coverage 30.54% 30.59% +0.04%
- Complexity 194 198 +4
============================================
Files 104 104
Lines 2668 2667 -1
Branches 234 234
============================================
+ Hits 815 816 +1
+ Misses 1786 1780 -6
- Partials 67 71 +4
Continue to review full report at Codecov.
|
Annotating the java fields is sufficient, as long as there is a corresponding getter (which is generated by lombok in my case): gradle/gradle#7688 The conceptual problem with the cacheability of the task is this: |
Thank you for your quick response. We have noticed, that we can skip the lombok config generation all together since we don't have any specific configuration. |
How did you "skip the lombok config generation"? I have similar problem: builds are very slow, even when I already had a full build and did not change anything in the java code the generateEffectiveLombokConfig tasks run on the next build. We don't even have any lombok.config file in our project. |
The easiest way is to set the System Property in your build.gradle: But maybe there should be a configuration option to ignore external files and rely on clean build in case of external file changes. |
The current annotations in LombokConfig are incorrect according to the javadoc, this Pullrequest is an attempt to fix it.
As stated in the Gradle javadoc https://docs.gradle.org/current/javadoc/org/gradle/api/tasks/InputFiles.html @InputFiles @input and @OutputFile have to be applied on getters instead of fields for them to be processed.
Enabling the caching reduced the build time in our project to a quarter as it also effects the caching of dependent tasks.