Circleci Sonarqube integration for gradle project

Trying to integrate circleci with sonarqube, repo is using bitbucket.
Below is the code set for sonar set up and sonar scan.

``` Preformatted text
name: Sonar scan
command: |
# Open ssh tunnel into Sonar
# Workaround CircleCi bug :
git branch -D master
# Run scanning job
TASK_URL=$(./gradlew -d sonar$CIRCLE_BRANCH$CIRCLE__TARGET_BRANCH | tee out | grep -Eo ‘http./api/ce/task.’)
# Get result and quality gates

Its not scanning the repo.


Welcome to the community!

You haven’t given much to go by here. What is happening? (i.e. logs)


But I get below error in build.

and at end these errors too

Is above config is fine for sonar scan from circleci?
Could you please help to pipeline success and push to sonar.?


From what I can tell of your analysis log screenshots, it seems that there’s an error in your compilation, not your analysis…?

In general, the full log, or at least the full error, presented in code-formatted text (``` on the line before and on the line after) is far preferable to screenshots.



The first thing I see here is

Google tells me that JPAAnnotationProcessor has to do with code generation, i.e. a step in the process way before you get to SonarQube analysis. Since with Java, you can only analyze after you’ve compiled, and since I believe this is a pre-compile step, I don’t believe this has anything to do with SonarQube.

Sorry, but I don’t think we can help you here.


Thanks Ann for the reply.
Let me check.

Thanks Ann!. Resolved the above error, but new one come for another repo.

Classes not found during the analysis : [org.openid4java.consumer.ConsumerException, org.openid4java.consumer.ConsumerManager,,,....]

Could you help to resolve this?


The general rule is one topic, one thread. This is a new question on a new repo. :slightly_smiling_face:

At the same time, I suspect this is not actually an ERROR but a warning? Anyway, that can be dealt with in a new thread with full logs


Thanks Ann!.
I will post new topic. Please reply