Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow per-cluster search config and use new text similarity for es6 #1581

Merged
merged 3 commits into from Jun 12, 2019

Conversation

Projects
None yet
2 participants
@barrucadu
Copy link
Contributor

commented Jun 12, 2019

$ ELASTICSEARCH_A_URI='http://localhost:9200' ELASTICSEARCH_B_URI='http://localhost:9201' bundle exec rake search:create_all_indices SEARCH_INDEX=all
...
$ curl localhost:9200/govuk/_settings 2>/dev/null | json_pp | grep -C5 similarity
               "total_fields" : {
                  "limit" : "2000"
               }
            },
            "number_of_replicas" : "1",
            "similarity" : {
               "default" : {
                  "type" : "classic"
               }
            },
            "number_of_shards" : "3"
$ curl localhost:9201/govuk/_settings 2>/dev/null | json_pp | grep -C5 similarity
$

Trello card

@bilbof

bilbof approved these changes Jun 12, 2019

@bilbof

This comment has been minimized.

Copy link
Contributor

commented Jun 12, 2019

Is there a way to test the clusters have different schemas applied?

@barrucadu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 12, 2019

I'm not sure, I can't see an obvious way.

@bilbof

This comment has been minimized.

Copy link
Contributor

commented Jun 12, 2019

I suppose in an integration test, you could instantiate all clusters, then use the ES client to inspect the settings and check they're what they should be?

@barrucadu

This comment has been minimized.

Copy link
Contributor Author

commented Jun 12, 2019

That's a bit tricky because we don't set the entire config, so the result of curl localhost:9200/govuk/_settings isn't the same as what we have in our yaml file.

We could check the yaml file is a subset of the ES-reported index config, but that wouldn't help in this case where we want to check that removing a key from the config file worked.

@barrucadu barrucadu merged commit 5b6cf2c into master Jun 12, 2019

1 of 2 checks passed

continuous-integration/jenkins/publishing-e2e-tests Publishing end-to-end tests failed on Jenkins
Details
continuous-integration/jenkins/branch This commit looks good
Details

@barrucadu barrucadu deleted the msw/per-cluster-config branch Jun 12, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.