- fix info about files
- add info about InstantSend
This commit is contained in:
UdjinM6 2017-03-20 04:21:04 +03:00 committed by GitHub
parent 8b6a06c09f
commit 92eaefb830
2 changed files with 66 additions and 3 deletions

View File

@ -1,15 +1,20 @@
* banlist.dat: stores the IPs/Subnets of banned nodes
* bitcoin.conf: contains configuration settings for bitcoind or bitcoin-qt
* bitcoind.pid: stores the process id of bitcoind while running
* dash.conf: contains configuration settings for dashd or dash-qt
* dashd.pid: stores the process id of dashd while running
* blocks/blk000??.dat: block data (custom, 128 MiB per file); since 0.8.0
* blocks/rev000??.dat; block undo data (custom); since 0.8.0 (format changed since pre-0.8)
* blocks/index/*; block index (LevelDB); since 0.8.0
* chainstate/*; block chain state database (LevelDB); since 0.8.0
* database/*: BDB database environment; only used for wallet since 0.8.0
* db.log: wallet database log file
* debug.log: contains debug information and general logging generated by bitcoind or bitcoin-qt
* debug.log: contains debug information and general logging generated by dashd or dash-qt
* fee_estimates.dat: stores statistics used to estimate minimum transaction fees and priorities required for confirmation; since 0.10.0
* governance.dat: stores data for governance obgects
* masternode.conf: contains configuration settings for remote masternodes
* mncache.dat: stores data for masternode list
* mnpayments.dat: stores data for masternode payments
* netfulfilled.dat: stores data about recently made network requests
* peers.dat: peer IP address database (custom format); since 0.7.0
* wallet.dat: personal wallet (BDB) with keys and transactions
* .cookie: session RPC authentication cookie (written at start when cookie authentication is used, deleted on shutdown): since 0.12.0

58
doc/instantsend.md Normal file
View File

@ -0,0 +1,58 @@
##InstantSend Technical Information
InstantSend has been integrated into the Core Daemon in two ways:
* "push" notifications (ZMQ and `-instantsendnotify` cmd-line/config option);
* RPC commands.
####ZMQ
When a "Transaction Lock" occurs the hash of the related transaction is broadcasted through ZMQ using both the `zmqpubrawtxlock` and `zmqpubhashtxlock` channels.
* `zmqpubrawtxlock`: publishes the raw transaction when locked via InstantSend
* `zmqpubhashtxlock`: publishes the transaction hash when locked via InstantSend
This mechanism has been integrated into Bitcore-Node-Dash which allows for notification to be broadcast through Insight API in one of two ways:
* WebSocket: [https://github.com/dashpay/insight-api-dash#web-socket-api](https://github.com/dashpay/insight-api-dash#web-socket-api)
* API: [https://github.com/dashpay/insight-api-dash#instantsend-transactions](https://github.com/dashpay/insight-api-dash#instantsend-transactions)
####Command line option
When a wallet InstantSend transaction is successfully locked a shell command provided in this option is executed (`%s` in `<cmd>` is replaced by TxID):
```
-instantsendnotify=<cmd>
```
####RPC
Details pertaining to an observed "Transaction Lock" can also be retrieved through RPC, its important however to understand the underlying mechanism.
By default, the Dash Core daemon will launch using the following constant:
```
static const int DEFAULT_INSTANTSEND_DEPTH = 5;
```
This value can be overridden by passing the following argument to the Dash Core daemon:
```
-instantsenddepth=<n>
```
The key thing to understand is that this value indicates the number of "confirmations" a successful Transaction Lock represents. When Wallet RPC commands are performed (such as `listsinceblock`) this attribute is taken into account when returning information about the transaction. The value in `confirmations` field you see through RPC is showing the number of `"Blockchain Confirmations" + "InstantSend Depth"` (assuming the funds were sent via InstantSend).
There is also a field named `bcconfirmations`. The value in this field represents the total number of `"Blockchain Confirmations"` for a given transaction without taking into account whether it was InstantSend or not.
**Examples**
* InstantSend transaction just occurred:
* confirmations: 5
* bcconfirmations: 0
* InstantSend transaction received one confirmation from blockchain:
* confirmations: 6
* bcconfirmations: 1
* non-InstantSend transaction just occurred:
* confirmations: 0
* bcconfirmations: 0
* non-InstantSend transaction received one confirmation from blockchain:
* confirmations: 1
* bcconfirmations: 1