[cpp] Add poll-based async lookups
Search before asking
- [x] I searched in the issues and found nothing similar.
Description
#4559 adds Lookuper::Lookup(pk_row, PendingLookup&): the caller keeps one handle per lookup and waits on each. That works for "start now, wait later", but for fan-out the caller has to hold many handles and, waiting in order, sits behind the slowest lookup.
discussed in #4559, add a polling API next to the handle:
Result LookupAsync(const GenericRow& pk_row, uint64_t request_id);
Result Poll(int64_t timeout_ms, std::vector
Poll returns the lookups that finished, in completion order, each with its request_id, status and row. The same for PrefixLookuper.
Willingness to contribute
- [ ] I'm willing to submit a PR!
Hi @fresh-borzoni are you working on this? happy to take this
@pbanakar you can take it, thank you for helping with this 👍
Hi @fresh-borzoni submitted a PR & just resolved the merge conflicts, could you please take a look on this when you have some time! Thanks