Upgrading Gradle plugin from 4.2.1.3168 causes scan to take 1.5 hours

Template for a good new topic, formatted with Markdown:

  • ALM used GitHub
  • CI system used Jenkins
  • Scanner command used when applicable (private details masked)
  • Languages of the repository - Kotlin
  • Only if the SonarCloud project is public, the URL
    • And if you need help with pull request decoration, then the URL to the PR too
  • Error observed (wrap logs/code around with triple quotes ``` for proper formatting)
  • Steps to reproduce
    Upgrade gradle plugin from 4.2.1.3168 to 4.4.0.3356 causes the scan to take 1.5hours. Using the old version it takes 5 minutes.
  • Potential workaround

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

I can share a full log privately if need be.

1 Like

Anybody from sonar care to follow up on this?

Hello @Nikolay_Metchev,

Thank you for reaching out, I was checking what changes may have caused such a performance penalty, and there is a commit that may have added computational complexity: Avoid nested paths in sonar.sources/sonar.tests.

In order to speed up the investigation it would be of help to have the logs and, more importantly, a reproducer. Could you provide such info? It would be great to have a zip file with a small project on which the scanner command takes longer than expected.

Cheers

The site doesn’t appear to have private messages anymore. I can’t post the logs on a public forum.

Hello Nikolay,

Please excuse the delay.

Based on the logs you provided, there seem to be a couple of unexpected behaviors playing together to create this long scan time. I have created two tickets to track these bugs here and here. We are planning to work on some related work soon anyway, during which we may well be able to address this issue.

Until this is fixed, I would suggest not upgrading to the latest plugin version in this particular case.