-
Notifications
You must be signed in to change notification settings - Fork 40
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
ScrollRequest not work? #352
Comments
Hi @wfxr 👋 We should add high-level support for scrolling to this library. The scroll API is actually a little confusing. You need to issue a let client = SyncClient::builder().build()?;
// Just make sure our index exists
client.index("my-index").create().send()?;
// Issue a search request
let res = client.search::<Value>()
.index("my-index")
.body(json!({
"size": 100,
"query": {
"match_all": {}
}
}))
// Add the `scroll` parameter
.params_fluent(|p| p
.url_param("scroll", "1m"))
.send()?;
println!("{:?}", res);
Ok(()) We unfortunately don't currently expose the |
@KodrAus I literally just ran the query you posted above (independently for my own test index) and was surprised that the I only just started following this repo, but what is the typical tag/release timeline for this project? Would this small patch get tagged and released on it's own (soon) or will it get batched in with some other changes? |
@slaterb1 Welcome! So my bandwidth for supporting the project is a bit limited lately, but am actually working on a PR to add some nicer scrolling support at the moment that exposes the paged search responses either as an |
Here is a very simple scroll request, but I can't make it work. Did I get something wrong?
The error message is :
If I keep request body empty:
Another error showed:
The text was updated successfully, but these errors were encountered: