Details
-
Bug
-
Resolution: Timed out
-
Low
-
3.7.0
-
None
-
Severity 3 - Minor
-
Description
FishEye, when indexing git repositories, detects default branch on the remote repository. But this information is not persisted, so after instance restart, the default branch would be unknown until first slurp of remote repository detects new changes that needs to be indexed.
So for repositories where there is no activity in remote repository since last indexing, or where remote repositories are no longer available, the default branch name would be unknown.
Also, when remote repository has no default branch specified (git remote show <<URL>> returns "HEAD branch: (unknown)" for instance), the default branch would never be set) - perhaps fallback to master would be better?
This causes few problems with FishEye/Crucible:
- URLs to default branch (HEAD) would fail with "No revision found HEAD" error, because FishEye will be looking up null revision. See https://fisheye4.atlassian.com/browse/~raw,r=HEAD/activeobjects-git/pom.xml for instance
- branch reviews would not be able to suggest base branch correctly on branch review creation
- perhaps others, to be assessed
Suggested fix:
- persist default branch name locally (e.g. in var/cache/<REPO>/clone/fe_clone.properties file or in local clone (see https://confluence.atlassian.com/display/FISHKB/Setting+a+valid+HEAD+on+your+Git+repository)) between restarts
- ensure default branch is refreshed on every slurp, even when no change on remote repository is detected
Attachments
Issue Links
- is related to
-
FE-5864 Fisheye doesn't recognize Bitbucket Server default branch change
- Closed