mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-05-15 10:25:40 +00:00
feat(web): full-power RPC access + typed JSON proxy endpoint (#1983)
- extend web controller bindings to cover full RPC service set - update rpc_service API wiring and session/controller integration - generate trait-level json_call_method in rpc codegen - route restful proxy-rpc requests via scoped typed clients - add json-call regression tests and required Sync bound fixes~
This commit is contained in:
@@ -339,10 +339,14 @@ impl Session {
|
||||
self.data.clone()
|
||||
}
|
||||
|
||||
pub fn scoped_rpc_client(&self) -> SessionRpcClient {
|
||||
pub fn scoped_client<F: rpc_types::__rt::RpcClientFactory>(&self) -> F::ClientImpl {
|
||||
self.rpc_mgr
|
||||
.rpc_client()
|
||||
.scoped_client::<WebClientServiceClientFactory<BaseController>>(1, 1, "".to_string())
|
||||
.scoped_client::<F>(1, 1, "".to_string())
|
||||
}
|
||||
|
||||
pub fn scoped_rpc_client(&self) -> SessionRpcClient {
|
||||
self.scoped_client::<WebClientServiceClientFactory<BaseController>>()
|
||||
}
|
||||
|
||||
pub async fn get_token(&self) -> Option<StorageToken> {
|
||||
|
||||
Reference in New Issue
Block a user