Extract an LspStore object from Project, to prepare for language support over SSH (#17041)

For ssh remoting lsps we'll need to have language server support
factored out of project.

Thus that begins

Release Notes:

- N/A

---------

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-authored-by: Mikayla <mikayla@zed.dev>
This commit is contained in:
Conrad Irwin
2024-08-30 14:36:38 -07:00
committed by GitHub
co-authored by Max Brunsfeld Mikayla
parent 7c57ffafbd
commit 75d4c7981e
24 changed files with 7252 additions and 6466 deletions
+17 -3
View File
@@ -446,6 +446,15 @@ impl<T: 'static> PendingEntitySubscription<T> {
);
drop(state);
for message in messages {
let client_id = self.client.id();
let type_name = message.payload_type_name();
let sender_id = message.original_sender_id();
log::debug!(
"handling queued rpc message. client_id:{}, sender_id:{:?}, type:{}",
client_id,
sender_id,
type_name
);
self.client.handle_message(message, cx);
}
Subscription::Entity {
@@ -1516,7 +1525,12 @@ impl Client {
self.peer.send(self.connection_id()?, message)
}
pub fn send_dynamic(&self, envelope: proto::Envelope) -> Result<()> {
pub fn send_dynamic(
&self,
envelope: proto::Envelope,
message_type: &'static str,
) -> Result<()> {
log::debug!("rpc send. client_id:{}, name:{}", self.id(), message_type);
let connection_id = self.connection_id()?;
self.peer.send_dynamic(connection_id, envelope)
}
@@ -1728,8 +1742,8 @@ impl ProtoClient for Client {
self.request_dynamic(envelope, request_type).boxed()
}
fn send(&self, envelope: proto::Envelope) -> Result<()> {
self.send_dynamic(envelope)
fn send(&self, envelope: proto::Envelope, message_type: &'static str) -> Result<()> {
self.send_dynamic(envelope, message_type)
}
}