From 0ff84da5a2e5fcf2dd9ad952ee9afb22241de785 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Mon, 19 Dec 2022 20:03:55 -0800 Subject: cli: add XRPC query/rpc debug logging --- adenosine-cli/src/lib.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/adenosine-cli/src/lib.rs b/adenosine-cli/src/lib.rs index e232667..0db2cb4 100644 --- a/adenosine-cli/src/lib.rs +++ b/adenosine-cli/src/lib.rs @@ -61,6 +61,7 @@ impl XrpcClient { nsid: &Nsid, params: Option>, ) -> Result> { + log::debug!("XRPC GET endpoint={} params={:?}", nsid, params); let params: HashMap = params.unwrap_or_default(); let res = self .http_client @@ -121,6 +122,12 @@ impl XrpcClient { body: Option, ) -> Result> { let params: HashMap = params.unwrap_or_default(); + log::debug!( + "XRPC POST endpoint={} params={:?} body={:?}", + nsid, + params, + body + ); let mut req = self .http_client .post(format!("{}/xrpc/{}", self.host, nsid)) -- cgit v1.2.3