Skip to content
Snippets Groups Projects
Closed RFC: Move Sourcegraph Enterprise code into this OSS repository?
  • View options
  • RFC: Move Sourcegraph Enterprise code into this OSS repository?

  • View options
  • Closed Issue created by Warren Gifford

    Created by: sqs

    We (Sourcegraph teammates) want to be as efficient as possible in improving Sourcegraph for you. Most Sourcegraph code is open source, but certain features are deemed Sourcegraph Enterprise and are not open source. These non-open-source features' code lives in a separate repository. Dealing with two repositories adds a lot of friction to our development processes, both in day-to-day work and in creation and maintenance of the tooling to support this development scenario.

    Our current setup is:

    • We clone this repository to ~/src/github.com/sourcegraph/sourcegraph using the Git remote name oss.
    • We add a Git remote ent pointing to https://github.com/sourcegraph/enterprise (the non-open-source repository that tracks this repository via bidirectional cherry-picking, and also contains an enterprise/ dir with all Sourcegraph Enterprise features).

    This has problems that reduce our productivity:

    • It is a manual (semi-scripted) process to keep oss/master and ent/master in sync, which causes merge conflicts and confusion.
    • Our issue tracker is split between sourcegraph/sourcegraph and sourcegraph/enterprise, which causes confusion and means that users don't benefit from being able to search issues and see our internal issue discussions.
    • We need to switch between the oss/master and ent/master branches a lot in local development. This means killing the dev server and starting up the other one, which takes 30-75s. We could fix this specific issue, but other pains remain (e.g., hub and Git UI tools not working well with local branch names != remote branch names).
    • Our build pipeline is only fully configured for Enterprise; the OSS repository only runs a subset of it, so some CI failures are only caught after the OSS commits are cherry-picked into Enterprise.

    To solve these problems, we are considering moving all Sourcegraph Enterprise (non-OSS) code into this repository's enterprise/ directory. This would mean we would work entirely in a single repository, which solves all of these problems. Enterprise code is already neatly factored out, so this is a quick operation if we decide to do it.

    Pros:

    • We will be much(?) more productive in improving Sourcegraph (both in OSS and Enterprise).
    • The issue tracker will be more useful.
    • You can view Sourcegraph Enterprise code, in case it's useful when troubleshooting. The code would remain non-open-source (using, e.g., GitLab EE's license).

    Cons:

    • This repository would no longer be 100% open source. The enterprise/ directory would be publicly visible but not open source (using, e.g., GitLab EE's license). All files outside of that directory would remain 100% open source.

    We can provide an auto-generated Git repository export of everything minus enterprise/ for people who need to clone a 100%-OSS repository.

    We are posting this to gather community feedback on this idea.

    GitLab is planning to do the same thing:

    Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first