Check housekeeping execution?

We use Sonarqube 8.4.1 Enterprise.
Is it possible to check housekeeping execution?
Indeed, there is no filter in Administration / Projects / Background Tasks…
We have a lot of old analyzed branches on projects (that doesn’t match “Branches to keep when inactive” and should be deleted…).
Thanks for your help.

Hello @sgummb,

I can’t be certain without more details but I suspect that you fell into a trap that our users often fall into: The housekeeping of branches is not something that happens in the background on the SonarQube platform. It is executed per project, when an analysis of that project is sent to SonarQube (at the end of the project analysis background task).
As a consequence, if you suddenly stop analysing a project, all the branches of that project will remain in SonarQube forever without being deleted.

If you already knew of the above behaviour and still you have a problem, please explain in more details and provide some evidence of the problem eg a branch:

  • not marked for permanent retention
  • that has not been analyzed since a long time, and that was not deleted,
  • even though the project (on another branch) has been re-analyzed recently…

Olivier

Hello @OlivierK,

I felt in the trap ! So I won’t find anything in background tasks!


Attached project was analyzed 1 month ago (October 20th) but old branches, not protected, remain… so it is not normal?

Mmmh… I can’t find an explanation in that case, except if you upgraded from an older version (ie 8.0 or older) where branch deletion did not work the same way AFTER the last analysis of your master branch. Would that be a possibility ?

I started a new analyze on master branch today, and old branches were removed.
We upgraded from 8.3 to 8.4.1 in August, and to 8.5.1 yesterday.

OK. So it sounds like the housekeeping works now ?
I think it would be difficult to go back in time to understand what happened (and by the way there were no known cases of housekeeping not working in older versions of SonarQube, so I don’t think the upgrade fixed a bug, rather that there was an explainable corner case scenario that caused this)

It’s OK now, thanks for your help :+1:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.