You've already forked electroncash-protocol
Clean up shutdown logic and logging
Add RPC "stop" command, and document it. Fixes the 2nd part of #100
This commit is contained in:
@@ -234,8 +234,9 @@ Terminating ElectrumX
|
||||
=====================
|
||||
|
||||
The preferred way to terminate the server process is to send it the
|
||||
INT or TERM signals. For a daemontools supervised process this is best
|
||||
done by bringing it down like so::
|
||||
**stop** RPC command, or alternatively on Unix the INT or TERM
|
||||
signals. For a daemontools supervised process this can be done by
|
||||
bringing it down like so::
|
||||
|
||||
svc -d ~/service/electrumx
|
||||
|
||||
|
||||
+14
-2
@@ -2,14 +2,26 @@ The ElectrumX RPC Interface
|
||||
===========================
|
||||
|
||||
You can query the status of a running server, and affect its behaviour
|
||||
using the RPC interface.
|
||||
by sending JSON RPC commands to the LocalRPC port it is listening on.
|
||||
This is best done using the electrumx_rpc.py script provided.
|
||||
|
||||
The general form of invocation is:
|
||||
|
||||
``electrumx_rpc.py <command> [arg1 [arg2...]``
|
||||
``electrumx_rpc.py [-p PORT] <command> [arg1 [arg2...]``
|
||||
|
||||
The port to send the commands to can be specified on the command line,
|
||||
otherwise it is taken from the environment variable **RPC_PORT**, or
|
||||
8000 is used if that is not set.
|
||||
|
||||
The following commands are available:
|
||||
|
||||
* **stop**
|
||||
|
||||
Flush all cached data to disk and shut down the server cleanly, as
|
||||
if sending the KILL signal. Be patient - during initial sync
|
||||
flushing all cached data to disk can take several minutes. This
|
||||
command takes no arguments.
|
||||
|
||||
* **getinfo**
|
||||
|
||||
Returns a summary of server state. This command takes no arguments.
|
||||
|
||||
Reference in New Issue
Block a user