Skip to content

zoekt-sourcegraph-indexserver: Use tarball redirect#17

Closed
tsenart wants to merge 1 commit intomasterfrom
git-archive-redirection
Closed

zoekt-sourcegraph-indexserver: Use tarball redirect#17
tsenart wants to merge 1 commit intomasterfrom
git-archive-redirection

Conversation

@tsenart
Copy link
Copy Markdown
Contributor

@tsenart tsenart commented Jul 24, 2019

This commit makes zoekt-sourcegraph-indexserver ask for a redirect to
from the internal frontend git tar endpoint to the new gitserver archive
endpoint.

Part of https://github.com/sourcegraph/sourcegraph/issues/4949

This commit makes zoekt-sourcegraph-indexserver ask for a redirect to
from the internal frontend git tar endpoint to the new gitserver archive
endpoint.

Part of https://github.com/sourcegraph/sourcegraph/issues/4949
Copy link
Copy Markdown
Member

@keegancsmith keegancsmith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I commented in the other PR, but why do we opt-in to this behaviour? Can't we just always do the redirect?

@tsenart
Copy link
Copy Markdown
Contributor Author

tsenart commented Jul 25, 2019

I commented in the other PR, but why do we opt-in to this behaviour? Can't we just always do the redirect?

We can, but I wanted to make this change safe to roll-out. We should deploy the frontend and git-server first, then zoekt.

In customer deployments, it's possible that zoekt and the frontend get deployed first, and git-server last. In that scenario redirects to /archive wouldn't work, but that'd be temporary and recover quickly.

@keegancsmith
Copy link
Copy Markdown
Member

You should probably just control that in sourcegraph-frontend rather than the client opting in and exposing this implementation detail here. TBH given how we do releases to customers there isn't a nice way to do this without overengineering. So I would just always rely on the redirect, or have a temporary env var for sourcegraph-frontend to pick the codepath, and that way we can experiment.

@tsenart
Copy link
Copy Markdown
Contributor Author

tsenart commented Jul 25, 2019

You should probably just control that in sourcegraph-frontend rather than the client opting in and exposing this implementation detail here.

Yeah, I realise that there's no difference. We don't need this change. If the frontend we hit has already been upgraded, then we'll follow the redirect in the response. Otherwise, we use the old behaviour.

@tsenart tsenart closed this Jul 25, 2019
@tsenart tsenart deleted the git-archive-redirection branch July 25, 2019 14:49
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.

3 participants