Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

sonar bitbucket server-unable to fetch data from sonar qube server

Shweta s
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 6, 2018

was not able to fetch data for Sonar project com.sgx.bt.tsnext:feature/BT-4662

RFQ_CHANGES_FOR_ALERTS".

Either your pull request has not been analyzed yet, a non-existing Sonar project is referenced, you use the new branching feature of SonarQube 6.7 but haven't enabled this in the repository settings or you have upgraded Sonarqube without restarting the plugin 

(disabling and re-enabling in the UPM ). you can configure the sonar project in the 

repository settings

1 answer

0 votes
Michael Rüegg _Mibex Software_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 7, 2018

Hi,

It looks like the plug-in wasn't able to find Sonar results for this branch. Could you please make sure that there is a project with this branch in SonarQube? If there is, please create a support request in our service desk so that we can analyze this in more detail (maybe by exchanging debug logs).

Thanks,

Michael from Mibex Software

priyang patel June 19, 2019

I am also facing similar issue, I am having a develop branch and from there we create feature branch and once code is done. we merge from feature --> develop branch. 

 

Above error encountered when I am having analysis published for develop branch and now i am trying to create a pull request from feature to develop. 

 

Does it means that I need sonar analysis for feature branch needs to be available to get results ? 

priyang patel June 19, 2019

Its bit urgent , if someone please look into it ? 

Michael Rüegg _Mibex Software_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 19, 2019

@priyang patelExactly, the feature branch needs to be analyzed as well.

priyang patel June 19, 2019

So this plugin needs both develop and feature branch analyzed before we create pull request Correct ? 

Like Valentina Mannara likes this
Michael Rüegg _Mibex Software_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 19, 2019

Technically, the feature (source) branch of the pull request is enough when you use "Leak Period" mode. If you use "Branch-based" mode, then both branches need to be analyzed. It depends a bit if you want to use "Leak Period" or not (requires you to configure sonar.projectVersion). Does that help you?

priyang patel June 19, 2019

I have disabled branch based mode and enabled leak period, still getting below error.

 

 

Was not able to fetch data for Sonar project "AAA:develop:Feature/abc_1". Either your pull request has not been analyzed yet, a non-existing Sonar project is referenced, you use the new branching feature of SonarQube >= 6.7 but have not enabled this in the repository settings or you have upgraded SonarQube without restarting the plug-in (disabling and re-enabling in the UPM). You can configure the Sonar project in the 

priyang patel June 19, 2019

One more question 

We are having around 50+ visual studio solutions in my repository , I am creating separate 50 projects in sonarqube for a feature branch.  Now when a developer commit changes he /she commit against the same repository and they will create only one pull-request. Now that pull request could have code for multiple solutions (and multiple projects in sonar). for this situation how are you suggesting to configure this utility. 

Michael Rüegg _Mibex Software_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 19, 2019

I guess your project key is "AAA". Could you please make sure that you have "AAA" in the field "Project base key" in the repository settings of the plug-in?

priyang patel June 19, 2019

Yes , key is present in project base key. 

But one thing I want to understand, in any case feature (source) branch , from where I am creating pull request to merge to develop branch, needs to be analyzed first to use this plugin ? 

In short source branch needs to be analyzed and published to soanr server before we create pull request.

Michael Rüegg _Mibex Software_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 19, 2019

That's correct, the source branch needs to be analyzed first. Could you please make sure that your project base key is exactly "AAA", but not "AAA:develop"?

priyang patel June 20, 2019

Sure , The constraint what we are having is we cant publish statistics for "feature" branch in advance , as we are using one common instance for whole organization and there are constraints which is stopping us to send feature file statistics to sonar instance. 

Just want to understand that your tool  is internally fetching details from sonar server for the source branch and show to bit bucket. Its not generating and showing new debt on runtime. 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events