Skip to content
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

SonarQube Pipelines run successfully but no data in dashboard - v1.0.2-beta1 #8091

Closed
mrpaapi opened this issue Sep 24, 2024 · 5 comments · Fixed by #8137 or #8202
Closed

SonarQube Pipelines run successfully but no data in dashboard - v1.0.2-beta1 #8091

mrpaapi opened this issue Sep 24, 2024 · 5 comments · Fixed by #8137 or #8202
Assignees
Labels
devops Something about CI/CD (devops) severity/p1 This bug affects functionality or significantly affect ux type/bug This issue is a bug type/question This issue is a question

Comments

@mrpaapi
Copy link

mrpaapi commented Sep 24, 2024

Looks like SonarQube Dashboard is crashing. After successful import using pipelines, dashboard has no data.

image

@mrpaapi mrpaapi added the type/question This issue is a question label Sep 24, 2024
@mrpaapi mrpaapi changed the title SonarQube Pipelines run successfully but no data in dashboard SonarQube Pipelines run successfully but no data in dashboard - v1.0.2-beta1 Sep 24, 2024
Copy link

dosubot bot commented Sep 24, 2024

Hello @mrpaapi! I'm here to help you with any bugs, questions, or contributions you may have. If you need assistance, feel free to ask. Dosu

I found two similar closed issues that might be relevant to your problem:

  1. [Bug][Dashboard] Wrong bug title in the Sonarqube dashboard: This issue was resolved by modifying the character set of several tables. The suggested solution was to run the following scripts to change the collation, then run the SonarQube blueprint again:

    ALTER TABLE _tool_sonarqube_projects CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE _tool_sonarqube_issues CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE _tool_sonarqube_issue_code_blocks CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE _tool_sonarqube_hotspots CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE _tool_sonarqube_file_metrics CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE _tool_sonarqube_accounts CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE cq_projects CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE cq_issues CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE cq_issue_code_blocks CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
    ALTER TABLE cq_file_metrics CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;

    You can find more details here [1].

  2. [Bug][Sonarqube] Lack of metrics for dashboard: This issue was resolved by adding the number of lines metric. You can find more details here [2].

Additionally, common reasons for the SonarQube dashboard displaying 'No data' after a successful pipeline run could include:

  • Data Scope Configuration: Ensure that the correct SonarQube projects and data entities are selected during the data scope configuration.
  • Sync Policy: Verify that the sync frequency and other sync settings are correctly configured.
  • Data Collection Issues: Check if there were any errors during the data collection process.

For more detailed troubleshooting, you can refer to the Troubleshooting section or the SonarQube Configuration Documentation [3][4].

To continue talking to Dosu, mention @dosu.

@dosubot dosubot bot added devops Something about CI/CD (devops) severity/p1 This bug affects functionality or significantly affect ux type/bug This issue is a bug labels Sep 24, 2024
@klesh
Copy link
Contributor

klesh commented Sep 24, 2024

Looks like a known issue to me. Can you confirm? @Startrekzky

@mrpaapi
Copy link
Author

mrpaapi commented Sep 24, 2024

I ran this but still no Luck

can you run the following scripts to change collation, then run the sonarqube bp again:
ALTER TABLE _tool_sonarqube_projects CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE _tool_sonarqube_issues CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE _tool_sonarqube_issue_code_blocks CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE _tool_sonarqube_hotspots CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE _tool_sonarqube_file_metrics CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE _tool_sonarqube_accounts CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE cq_projects CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE cq_issues CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE cq_issue_code_blocks CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
ALTER TABLE cq_file_metrics CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;

@mrpaapi
Copy link
Author

mrpaapi commented Sep 25, 2024

Any update please? @klesh @Startrekzky @nathenharvey @tonyjw

@VadimVoykin
Copy link

Hello @Startrekzky!
We managed to determine that the issue lies in the Grafana queries. In order to fix it, we changed the Data Source of each "Panel" from "Mixed" to "mysql" and changed the table in the query by appending the "lake." prefix.
2024-10-01_09h13_18

Startrekzky pushed a commit to merico-dev/lake that referenced this issue Oct 10, 2024
klesh pushed a commit that referenced this issue Oct 10, 2024
Co-authored-by: Startrekzky <kaiyun.zhang@merico.dev>
Startrekzky added a commit to merico-dev/lake that referenced this issue Oct 11, 2024
Co-authored-by: Startrekzky <kaiyun.zhang@merico.dev>
klesh pushed a commit that referenced this issue Oct 11, 2024
Co-authored-by: Startrekzky <kaiyun.zhang@merico.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
devops Something about CI/CD (devops) severity/p1 This bug affects functionality or significantly affect ux type/bug This issue is a bug type/question This issue is a question
Projects
None yet
4 participants