Commit c5aac229 authored by Valery Sizov's avatar Valery Sizov Committed by Sean McGivern

add a note to update guide about re-creating ES index

parent 3f3cb349
......@@ -264,6 +264,22 @@ sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production
If all items are green, then congratulations, the upgrade is complete!
### 13. Elasticsearch index update (if you currently use Elasticsearch)
In 9.3 release we changed the index mapping to improve partial word matching. Please re-create your index by using one of two ways listed below:
1. Re-create the index. The following command is acceptable for not very big GitLab instances (storage size no more than few gigabytes).
```
# Omnibus installations
sudo gitlab-rake gitlab:elastic:index
# Installations from source
bundle exec rake gitlab:elastic:index
```
1. For very big GitLab instances we recommend following [Add GitLab's data to the Elasticsearch index](../integration/elasticsearch.md#add-gitlabs-data-to-the-elasticsearch-index).
## Things went south? Revert to previous version (9.2)
### 1. Revert the code to the previous version
......
......@@ -379,7 +379,7 @@ describe Gitlab::Elastic::SearchResults, lib: true do
blobs = results.objects('blobs')
expect(blobs.first['_source']['blob']['content']).to include('def')
expect(results.blobs_count).to eq 5
expect(results.blobs_count).to eq 7
end
it 'finds blobs from public projects only' do
......@@ -388,10 +388,11 @@ describe Gitlab::Elastic::SearchResults, lib: true do
Gitlab::Elastic::Helper.refresh_index
results = described_class.new(user, 'def', [project_1.id])
expect(results.blobs_count).to eq 5
expect(results.blobs_count).to eq 7
results = described_class.new(user, 'def', [project_1.id, project_2.id])
expect(results.blobs_count).to eq 10
expect(results.blobs_count).to eq 14
end
it 'returns zero when blobs are not found' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment