From 643605c79fdf90cd4c873122a1bbbd34ea647267 Mon Sep 17 00:00:00 2001 From: thephez Date: Mon, 19 Aug 2019 15:44:31 -0400 Subject: [PATCH] RPC - Add disconnectnode nodeid parameter --- .../devdoc/dash-core/rpcs/quick-reference.md | 2 +- .../dash-core/rpcs/rpcs/disconnectnode.md | 20 +++++++++++++++++-- _includes/layout/base/rpc-table.html | 2 +- 3 files changed, 20 insertions(+), 4 deletions(-) diff --git a/_includes/devdoc/dash-core/rpcs/quick-reference.md b/_includes/devdoc/dash-core/rpcs/quick-reference.md index 2aaeb224..5d914b88 100644 --- a/_includes/devdoc/dash-core/rpcs/quick-reference.md +++ b/_includes/devdoc/dash-core/rpcs/quick-reference.md @@ -222,7 +222,7 @@ These RPCs are all Dash-specific and not found in Bitcoin Core * [AddNode][rpc addnode]: {{summary_addNode}} {{UPDATED0_14_0}} * [ClearBanned][rpc clearbanned]: {{summary_clearBanned}} {{NEW0_12_0}} -* [DisconnectNode][rpc disconnectnode]: {{summary_disconnectNode}} {{NEW0_12_0}} {{UPDATED0_14_1}} +* [DisconnectNode][rpc disconnectnode]: {{summary_disconnectNode}} {{DASH_UPDATED0_14_1}} {{UPDATED0_14_1}} * [GetAddedNodeInfo][rpc getaddednodeinfo]: {{summary_getAddedNodeInfo}} {{DASH_UPDATED0_12_3}} {{UPDATED0_14_0}} * [GetConnectionCount][rpc getconnectioncount]: {{summary_getConnectionCount}} * [GetNetTotals][rpc getnettotals]: {{summary_getNetTotals}} {{UPDATED0_12_0}} diff --git a/_includes/devdoc/dash-core/rpcs/rpcs/disconnectnode.md b/_includes/devdoc/dash-core/rpcs/rpcs/disconnectnode.md index 175e32f7..cdf818f5 100644 --- a/_includes/devdoc/dash-core/rpcs/rpcs/disconnectnode.md +++ b/_includes/devdoc/dash-core/rpcs/rpcs/disconnectnode.md @@ -22,7 +22,15 @@ The `disconnectnode` RPC {{summary_disconnectNode}} t: "string" p: "Required
(exactly 1)" d: "The node you want to disconnect from as a string in the form of `:`.

*Updated in Bitcoin Core 0.14.1*" +{% enditemplate %} +*Parameter #2---nodeid* + +{% itemplate ntpd1 %} +- n: "nodeid" + t: "number" + p: "Optional" + d: "The node ID (see `getpeerinfo` for node IDs)" {% enditemplate %} *Result---`null` on success or error on failed disconnect* @@ -35,9 +43,9 @@ The `disconnectnode` RPC {{summary_disconnectNode}} {% enditemplate %} -*Example from Dash Core 0.12.2* +*Example from Dash Core 0.14.1* -Disconnects following node from your node. +Disconnects following node by address. {% highlight bash %} dash-cli -testnet disconnectnode 192.0.2.113:19999 @@ -45,6 +53,14 @@ dash-cli -testnet disconnectnode 192.0.2.113:19999 Result (no output from `dash-cli` because result is set to `null`). +Disconnects following node by id. + +{% highlight bash %} +dash-cli -testnet disconnectnode "" 3 +{% endhighlight %} + +Result (no output from `dash-cli` because result is set to `null`). + *See also* * [AddNode][rpc addnode]: {{summary_addNode}} diff --git a/_includes/layout/base/rpc-table.html b/_includes/layout/base/rpc-table.html index 6031dd29..79d8f9d3 100644 --- a/_includes/layout/base/rpc-table.html +++ b/_includes/layout/base/rpc-table.html @@ -395,7 +395,7 @@ th.tg-sort-header::-moz-selection { background:transparent; }th.tg-sort-header:: Network DisconnectNode Y - + Updated in 0.14.1.0 Network