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

Build suggesters "manually" against each solr replica #204

Merged
merged 1 commit into from
Sep 19, 2024

Conversation

billdueber
Copy link
Collaborator

We were dealing with some instabilities in the k8s cluster in 2024.09 when we wanted to release this, resulting nodes loosing track of zookeeper and suggesters not getting built (calls would time out). Attempt to brute-force this by hitting the individual solr URLs directly, taking advantage of knowledge about how many replicas and what they're called that we'd really rather not have to know.

NOTE: Once it's determined we don't need this hack, tear the relevant code in MedInstaller:IndexingSteps#index (after the second call to @build_collection.commit), leaving only a single rebuild_suggesters and call it a day.

To run in once for each configured solr replica, we need the following:

  • ENV[DIRECT_URLS_TO_SOLR_REPLICAS]: A space-delimited set of urls of the form "http://solr-solrcloud-1:8083" or whatever. This is the same format as the generic (cluster-level) connection string found in ENV[SOLR_URL] (e.g., no trailing "solr")
  • A non-falsey value for ENV[MANUALLY_BUILD_SUGGESTERS] to enable it.

We were dealing with some instabilities in the k8s cluster in 2024.09 when we wanted
to release this, resulting nodes loosing track of zookeeper and suggesters not getting
built (calls would time out). Attempt to brute-force this by hitting the individual
solr URLs directly, taking advantage of knowledge about how many replicas and what
they're called that we'd really rather not have to know.

NOTE: Once it's determined we don't need this hack, tear the relevant code in
MedInstaller:IndexingSteps#index (after the second call to @build_collection.commit),
leaving only a single `rebuild_suggesters` and call it a day.

To run in once for each configured solr replica, we need the following:

  * ENV[DIRECT_URLS_TO_SOLR_REPLICAS]: A space-delimited set of urls of the form
    "http://solr-solrcloud-1:8083" or whatever. This is the same format as the
    generic (cluster-level) connection string found in ENV[SOLR_URL] (e.g., no trailing "solr")
  * A non-falsey value for ENV[MANUALLY_BUILD_SUGGESTERS] to enable it.
@billdueber billdueber merged commit b9a9a71 into main Sep 19, 2024
0 of 2 checks passed
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.

1 participant