search: New old search implementation (#39956)
This is an in-progress work on changing how task scheduler affects performance of project search. Instead of relying on tasks being executed at a discretion of the task scheduler, we want to experiment with having a set of "agents" that prioritize driving in-progress project search matches to completion over pushing the whole thing to completion. This should hopefully significantly improve throughput & latency of project search. Release Notes: - Improved project search performance --------- Co-authored-by: Smit Barmase <smit@zed.dev> Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This commit is contained in:
co-authored by
Smit Barmase
Smit Barmase
parent
85c2aa7325
commit
7c4fb5a899
@@ -639,9 +639,15 @@ impl HeadlessProject {
|
||||
PathStyle::local(),
|
||||
)?;
|
||||
let results = this.update(&mut cx, |this, cx| {
|
||||
this.buffer_store.update(cx, |buffer_store, cx| {
|
||||
buffer_store.find_search_candidates(&query, message.limit as _, this.fs.clone(), cx)
|
||||
})
|
||||
project::Search::local(
|
||||
this.fs.clone(),
|
||||
this.buffer_store.clone(),
|
||||
this.worktree_store.clone(),
|
||||
message.limit as _,
|
||||
cx,
|
||||
)
|
||||
.into_handle(query, cx)
|
||||
.matching_buffers(cx)
|
||||
})?;
|
||||
|
||||
let mut response = proto::FindSearchCandidatesResponse {
|
||||
|
||||
Reference in New Issue
Block a user