-
Suggestion
-
Resolution: Unresolved
Problem Definition
When you have Fisheye integrated with Bitbucket Server via Application Links and add a Bitbucket repository as such in Fisheye (i.e., not as regular Git repo), and the repository gets renamed only in Bitbucket Server afterwards, Fisheye will still receive the remote event notification from Bitbucket Server and as expected will fail to trigger the incremental index because the new repository URL will not be found in Fisheye.
The problem is that only when debug logging is enabled Fisheye will write in the logs that the remote event was ignored because it is considered "non-local" (i.e., no repositories with the new URL could be found locally). In addition to adding this notification in regular logging, the admin web interface should show a notification somewhere as well.
Steps to Reproduce
- Integrate Fisheye 4.7.0 with Bitbucket Server 5.7.3 via Application Links
- Create the remote consumer tokens
- Add the Bitbucket repository to Fisheye
- Let Fisheye index the repository
- Commit and push changes to Bitbucket Server and notice that this change will show up in Fisheye almost immediately, and the following is written in both application logs:
- Bitbucket Server dispatches the remote event notification:
2020-02-18 15:03:31,301 DEBUG [events.remote.ratelimit.threads:thread-1] c.a.e.r.impl.RemoteEventDispatcher Found dispatch batches: List((https://my.company.com/fisheye/rest/remote-event-consumer/latest/events/stash-repository-refs-changed-remote-event,com.atlassian.stash.plugin.remote.event.StashRepositoryRefsChangedEvent@29dd9872[cloneLinks=[CloneLink{name=http, href=https://217216x710826@git.company.com/scm/abc/myrepo.git}, CloneLink{name=ssh, href=ssh://git@git.company.com:7999/abc/myrepo.git}],repositoryProject=ABC,repositorySlug=myrepo,committer=217216x710826,sourceId=<null>,sourceUrl=<null>]))
- Bitbucket Server dispatches the remote event notification:
-
- Fisheye receives the remote event notification, triggers an incremental indexing, and incremental indexing starts immediately:
2020-02-18 15:03:31,341 DEBUG [qtp1095352419-8907 ] com.atlassian.event.remote.impl.rest.RemoteEventConsumerResource RemoteEventConsumerResource-receiveEvent - Publishing event com.atlassian.stash.plugin.remote.event.StashRepositoryRefsChangedEvent@69979e14[cloneLinks=[CloneLink{name=ssh, href=ssh://git@git.company.com:7999/abc/myrepo.git}, CloneLink{name=http, href=https://217216x710826@git.company.com/scm/abc/myrepo.git}],repositoryProject=ABC,repositorySlug=myrepo,committer=217216x710826,sourceId=e784b133-58eb-3726-b9a3-e6611271704c,sourceUrl=https://git.company.com] from request 71602fa6-79d2-4077-815c-46395eb5da5f to capability stash-repository-refs-changed-remote-event 2020-02-18 15:03:31,342 DEBUG [qtp1095352419-8907 ] fisheye DefaultRepositoryAdminService-incrementalIndex - Incremental index triggered for repository myrepo 2020-02-18 15:03:31,350 DEBUG [IncrPing3 myrepo ] fisheye RepositoryStatus-setMessage - Status change [myrepo]: Contacting repository.
- Fisheye receives the remote event notification, triggers an incremental indexing, and incremental indexing starts immediately:
- Rename the repository in Bitbucket (which will make the clone URL change)
- Commit and push changes to Bitbucket Server and notice that this change will not show up in Fisheye:
- Bitbucket Server dispatches the remote event notification:
2020-02-18 15:05:09,569 DEBUG [events.remote.ratelimit.threads:thread-3] c.a.e.r.impl.RemoteEventDispatcher Found dispatch batches: List((https://my.company.com/fisheye/rest/remote-event-consumer/latest/events/stash-repository-refs-changed-remote-event,com.atlassian.stash.plugin.remote.event.StashRepositoryRefsChangedEvent@5f3b7030[cloneLinks=[CloneLink{name=http, href=https://217216x710826@git.company.com/scm/abc/mynewreponame.git}, CloneLink{name=ssh, href=ssh://git@git.company.com:7999/abc/mynewreponame.git}],repositoryProject=ABC,repositorySlug=mynewreponame,committer=217216x710826,sourceId=<null>,sourceUrl=<null>]))
- Bitbucket Server dispatches the remote event notification:
-
- Fisheye receives the remote event notification and ignores it:
2020-02-18 15:05:09,612 DEBUG [qtp1095352419-8907 ] com.atlassian.event.remote.impl.rest.RemoteEventConsumerResource RemoteEventConsumerResource-receiveEvent - Publishing event com.atlassian.stash.plugin.remote.event.StashRepositoryRefsChangedEvent@6c83fa24[cloneLinks=[CloneLink{name=http, href=https://217216x710826@git.company.com/scm/abc/mynewreponame.git}, CloneLink{name=ssh, href=ssh://git@git.company.com:7999/abc/mynewreponame.git}],repositoryProject=ABC,repositorySlug=mynewreponame,committer=217216x710826,sourceId=e784b133-58eb-3726-b9a3-e6611271704c,sourceUrl=https://git.company.com] from request a9a69d62-31a8-4e21-9131-a6e0f12d7751 to capability stash-repository-refs-changed-remote-event 2020-02-18 15:05:09,634 DEBUG [qtp1095352419-8907 ] com.atlassian.event.remote.impl.RemoteEventListener RemoteEventListener-onRemoteEvent - Ignoring non-local RemoteEvent com.atlassian.stash.plugin.remote.event.StashRepositoryRefsChangedEvent@6c83fa24[cloneLinks=[CloneLink{name=http, href=https://217216x710826@git.company.com/scm/abc/mynewreponame.git}, CloneLink{name=ssh, href=ssh://git@git.company.com:7999/abc/mynewreponame.git}],repositoryProject=ABC,repositorySlug=mynewreponame,committer=217216x710826,sourceId=e784b133-58eb-3726-b9a3-e6611271704c,sourceUrl=https://git.company.com]
- Fisheye receives the remote event notification and ignores it:
- As can be seen, the log line which says that the remote event was ignored is only written when DEBUG logging is enabled.
Suggested Solution
This log line should also be written when DEBUG logging is disabled - maybe with WARN logging level - and the admin interface should notify about this problem somewhere.
Workaround
Enable debug logging so as to see the message
- mentioned in
-
Page Failed to load
Hi everyone,
We have recently reviewed this issue and the overall interest in the problem. As the issue hasn't collect votes, watchers, comments, or support cases from many customers during its lifetime, it's very low on our priority list, and will not be fixed in the foreseeable future. That's why we've decided to resolve it as Not Being Considered.
Although we're aware the issue is still important to those of you who were involved in the conversations around it, we want to be clear in managing your expectations. The Fisheye&Crucible team is focusing on issues that have broad impact and high value, reflected by the number of comments, votes, support cases, and customers interested. Please consult the Implementation of New Features Policy for more details.
We understand how disappointing this decision may be, but we hope you'll appreciate our transparent approach and communication. Atlassian will continue to watch this issue for further updates, so please feel free to share your thoughts in the comments.
Kind regards
Marek Parfianowicz
Development Team Lead