Skip to content

fix: sonar issue collector time range split #5443

Merged
mappjzc merged 1 commit intoapache:mainfrom
leric:fix/sonar-issue-collector
Jun 13, 2023
Merged

fix: sonar issue collector time range split #5443
mappjzc merged 1 commit intoapache:mainfrom
leric:fix/sonar-issue-collector

Conversation

@leric
Copy link
Contributor

@leric leric commented Jun 12, 2023

Summary

Sonarqube issue collector will split result of issues/search by using createdBefore & createdAfter filter params, if the result exceed 100 pages.

The split end when createdBefore - createdAfter less than 1 second, which is createdBefore == createdAfter, and sonarqube api do not allow createdBefore and createdAfter to be equal. In some case sonar scanner failed to do backdating, all issues have same createdTime, the split will end up createdBefore == createdAfter, and fail with sonarqube api error.

This time range spliting don't need to be so acurate, this PR change the end condition to 10 seconds.

Does this close any open issues?

Closes #5442

Screenshots

Include any relevant screenshots here.

Other Information

Any other information that is important to this PR.

@leric leric marked this pull request as ready for review June 12, 2023 10:29
@leric leric force-pushed the fix/sonar-issue-collector branch from f7029d2 to 4440262 Compare June 13, 2023 02:27
@mappjzc mappjzc merged commit a9aa01a into apache:main Jun 13, 2023
@leric leric deleted the fix/sonar-issue-collector branch June 14, 2023 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug][sonarqube] Issue collector failed with error "Start bound cannot be larger or equal to end bound"

2 participants