(Question) Search Option "seq_no_primary_term" support
Hello all. It seems that “seq_no_primary_term” is not yet supported in Elastica's search Option value, is there any reason not to allow this to be specified? https://github.com/ruflin/Elastica/blob/8.x/src/Search.php#L406-L421
Official Documentation https://www.elastic.co/guide/en/elasticsearch/reference/current/search-search.html#search-search-api-request-body
I would like to add some information. After I implemented the retrieval of if_primary_term and if_seq_no, I found that calling save does not result in a Conflict error:
$Index->save(
$data,
[
'if_primary_term' => (int)$primaryTerm,
'if_seq_no' => (int)$seqNo,
]
);
Upon investigation, I discovered that the options list does not include if_primary_term and if_seq_no:
I believe that changing $options = $doc->getOptions($endpoint->getParamWhitelist()); would properly set the available option values. Is my understanding correct?
Hi @ryu818 , I think the main reason is that it is not supported yet is that nobody got around to add it. As you already digged into the code quite a bit, what do you think about opening a PR with the proposed change? This should make also the discussion if it works (or not) etc. much easier. I would really appreciate the contribution.