| 3640 | } |
| 3641 | |
| 3642 | async fn bkpr_inspect( |
| 3643 | &self, |
| 3644 | request: tonic::Request<pb::BkprinspectRequest>, |
| 3645 | ) -> Result<tonic::Response<pb::BkprinspectResponse>, tonic::Status> { |
| 3646 | let req = request.into_inner(); |
| 3647 | let req: requests::BkprinspectRequest = req.into(); |
| 3648 | debug!("Client asked for bkpr_inspect"); |
| 3649 | trace!("bkpr_inspect request: {:?}", req); |
| 3650 | let mut rpc = ClnRpc::new(&self.rpc_path) |
| 3651 | .await |
| 3652 | .map_err(|e| Status::new(Code::Internal, e.to_string()))?; |
| 3653 | let result = rpc.call(Request::BkprInspect(req)) |
| 3654 | .await |
| 3655 | .map_err(|e| Status::new( |
| 3656 | Code::Unknown, |
| 3657 | format!("Error calling method BkprInspect: {:?}", e)))?; |
| 3658 | match result { |
| 3659 | Response::BkprInspect(r) => { |
| 3660 | trace!("bkpr_inspect response: {:?}", r); |
| 3661 | Ok(tonic::Response::new(r.into())) |
| 3662 | }, |
| 3663 | r => Err(Status::new( |
| 3664 | Code::Internal, |
| 3665 | format!( |
| 3666 | "Unexpected result {:?} to method call BkprInspect", |
| 3667 | r |
| 3668 | ) |
| 3669 | )), |
| 3670 | } |
| 3671 | |
| 3672 | } |
| 3673 | |
| 3674 | async fn bkpr_list_account_events( |
| 3675 | &self, |