opensearch-net icon indicating copy to clipboard operation
opensearch-net copied to clipboard

[FEATURE] Missing Indices.ReloadSearchAnalyzers

Open pjninnis opened this issue 1 year ago • 2 comments

Is your feature request related to a problem?

C# Nugets OpenSearch.Client v1.5.0 OpenSearch.net v1.5.0

We’ve upgraded from NEST/ElasticSearch.net to the OpenSearch equivalents, and I can’t seem to find any replacement/equivalent for Indices.ReloadSearchAnalyzers

In the OpenSearch docs itself, it seems to exist at the low level (Refresh search analyzer - OpenSearch documentation) but I can’t seem to locate any equivalent in the client?

We use this to reload our synonyms without refreshing the whole index.

What solution would you like?

Add the equivalent call to OpenSearch.net that exists in ElasticSearch.net

What alternatives have you considered?

Without this functionality, we will need to explicitly call the OpenSearch server via an HTTP POST /_plugins/_refresh_search_analyzers/"index"

Do you have any additional context?

pjninnis avatar Oct 10 '23 20:10 pjninnis

While not ideal, you can work around this missing API and still take advantage of the client's configuration (e.g auth, hosts, SSL) by making the request with the low-level raw request method like so:

client.LowLevel.DoRequest<VoidResponse>(HttpMethod.POST, "/_plugins/_refresh_search_analyzers/" + indexName);

Xtansia avatar Oct 11 '23 00:10 Xtansia

Thomas, Thanks for the quick response. Yes, I can confirm that using the low level call works for me for now (and until the feature is added).

Thanks again.

Paul Ninnis

Senior Developer

M +61 412832453 <+61%20412%20832%20453>

On Wed, Oct 11, 2023 at 10:35 AM Thomas Farr @.***> wrote:

While not ideal, you can work around this missing API and still take advantage of the client's configuration (e.g auth, hosts, SSL) by making the request with the low-level raw request method like so:

client.LowLevel.DoRequest<VoidResponse>(HttpMethod.POST, "/_plugins/_refresh_search_analyzers/" + indexName);

— Reply to this email directly, view it on GitHub https://github.com/opensearch-project/opensearch-net/issues/391#issuecomment-1756485063, or unsubscribe https://github.com/notifications/unsubscribe-auth/AESKY4MXQNXDBY5CBCH3BJLX6XPDBAVCNFSM6AAAAAA526PWGCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJWGQ4DKMBWGM . You are receiving this because you authored the thread.Message ID: @.***>

pjninnis avatar Oct 11 '23 05:10 pjninnis