Move all code maintained by search team behind `Search` namespace
Problem
We have a mix of namespaces for how we organize code maintained by the search team, ie: Search
, Elasticsearch
, Elastic
, Gitlab::Search
, Gitlab::Elastic
, etc.
This is problematic for onboarding new developers and is difficult to maintain. In addition to complexity, we also have several potential tools for search, ie: elasticsearch
, opensearch
, zoekt
and postgresql
. We discussed moving those namespaces behind a more generic namespace, such as Search
, Search::Code
, and Search::Content
, but that is out of scope of this issue.
Proposal
Everything we have currently should fail rubocop rule that forces search related code to use “Search” namespace. These namespaces should make the cop raise an error:
- ^Elastic
- ^Elasticsearch
- ^Zoekt
- ^Gitlab::Elastic
- ^Gitlab::Elasticsearch
- ^Gitlab::Zoekt
- ^Gitlab::Search
Let's make a TODO list of the rubocop failures then slowly migrate everything behind Search
one by one.
I also propose that we convert Gitlab
namespace to Search
for brevity. For example: Gitlab::Elastic => Search::Elastic
Relevant team discussion (internal): https://docs.google.com/document/d/1oHf_ZspBvR0DgLU_9y4xBwGCnVJsPnQRyZQe9Hz1LXA/edit#bookmark=id.7of2fxsyy31y