-
Notifications
You must be signed in to change notification settings - Fork 427
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Add ability to force an immediate commit after indexing #2699
Comments
It should be feasible in the pushapi at least... |
I will give it a shot. |
Let me give you some pointers then:
* we don't have a proper routing layer at the moment. That's my goal for February. On Kubernetes, our current solution is to route requests using ingress rules:
|
Thanks for the pointers! I was actually thinking to piggyback on the ingest command rather than create a dedicated refresh/commit request. I feel like this command is pretty useless on its own without indexing data and more prone to abuse. Adding it as a parameter to the ingest command has clean and localized semantic of "I want all records in this request to be searchable before you come back to me". A standalone refresh command has a more vague semantic of "I want whatever is in flight right now anywhere in the index to be searchable" and has a global impact. |
That sounds much better, indeed. |
Move to quickwit 0.6 |
Adds an option to force a commit or wait for the next commit while issuing an ingest command. This commit only implements it for the ingest endpoint. If all records in the batch fail, the command will hang until at least one good document is indexed until quickwit-oss#2825 is merged in or the document parsing is moved to the early stages. See quickwit-oss#2699
* Add an option to force and wait for commit Adds an option to force a commit or wait for the next commit while issuing an ingest command. This commit only implements it for the ingest endpoint. If all records in the batch fail, the command will hang until at least one good document is indexed until #2825 is merged in or the document parsing is moved to the early stages. See #2699 * Add comments to the notification triggering logic * Fix rest tests * Remove extra current_offset setting --------- Co-authored-by: trinity-1686a <trinity@quickwit.io>
Adds an option to force a commit or wait for the next commit while issuing a bulk request command. See quickwit-oss#2699
Adds an option to force a commit or wait for the next commit while issuing a bulk request command. See #2699
Is there still more work to do on this issue? |
@trinity-1686a as you mentioned in your review, such feature could really benefit from a high level integration test. So, I am waiting for #2984 to add it in. Besides this I think this is done. |
Adds integration tests for different commit modes. Fixes quickwit-oss#2699
Adds integration tests for different commit modes. Fixes #2699
Is your feature request related to a problem? Please describe.
In my experience the simplest way to explain a difficult concept to a search engine user is by demonstrating this concept using a shell script that consists of several curl statements. I have been using this method for many years. You can find some examples of such scripts in imotov/elasticsearch-test-scripts repo.
Trying the same approach with quickwit uncovered 2 issues, one of which is absence of refresh operation that would force all indexed data to be searchable. It is necessary since most of the scripts need to perform the following operations:
Describe the solution you'd like
Add a flag to the bulk indexing operation that would trigger the commit operation and block execution until all data indexed so far is available to searchers.
Describe alternatives you've considered
An alternative is to reduce
commit_timeout_secs
and add sleep to the script. It is a viable solution if you need to run this script only once, but it is detrimental to quick iterations while debugging the script.Additional context
I found a relevant discussion in #1674 (comment) but since that issue is stalled and my motivation for this feature is quite different I would like to open a separate feature request.
The text was updated successfully, but these errors were encountered: