-
Notifications
You must be signed in to change notification settings - Fork 461
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
Unreasonably large configuration performance overhead #348
Comments
I think that line is using this static import: spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/FormatExtension.java Line 18 in b38ee5a
Which then calls this: spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/PluginGradlePreconditions.java Lines 24 to 31 in b38ee5a
not this: spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/PluginGradlePreconditions.java Lines 33 to 39 in b38ee5a
because target is an |
Sorry, I had linked the wrong line. Here is the real culprit: spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/SpotlessTask.java Line 118 in 249d3ca
|
Aha! Thanks very much for the bug find 👍 |
Published in 3.18.0 |
This line iterates the whole file collection, no matter if the task will execute or not. This is a large performance overhead, paid on every build invocation, no matter if spotless will be used or not. It should instead only check wether the collection itself is null.
spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/FormatExtension.java
Line 135 in b38ee5a
The text was updated successfully, but these errors were encountered: