Expand description
Implements CompactTxStreamer methods on the LightwalletdRPC type.
ConstantsΒ§
- MAX_
EXCLUDE_ πENTRIES - The maximum number of
excludeentries aGetMempoolTxclient can send. - MAX_
RAW_ πTRANSACTION_ BYTES - The maximum size of a raw transaction submitted by a client.
- RESPONSE_
BUFFER_ πSIZE - The maximum number of messages that can be queued to be streamed to a client.
- STREAM_
SEND_ πTIMEOUT - How long to wait for a backpressured send to a response stream before treating the consumer as hung and dropping the stream.
FunctionsΒ§
- address_
balance π - Fetches the total balance of a list of transparent addresses.
- address_
utxos π - Fetches the UTXOs for a list of transparent addresses, at or above the given start height,
at most
max_entriesof them. - block_
id_ πto_ hash_ or_ height - Converts a
BlockIdinto aHashOrHeight, using the hash if it is present and the height otherwise. - block_
range_ πstream - Returns a stream of compact blocks for the given block range.
- check_
address_ πcount - Returns an error if there are too many addresses in a single request.
- collect_
streamed_ πaddresses - Returns an error if
addressesexceedsMAX_REQUEST_ADDRESSES. Collects the transparent addresses a client streams, validating each one as it arrives and stopping at the first invalid or excess entry. - compact_
block π - Fetches a block and its note commitment tree sizes from the state, and converts
them into a
CompactBlock. - excluded_
txids π - Returns the transaction IDs excluded by an
Excludelist of shortened transaction IDs. - mempool_
transactions π - Fetches all transactions currently in the mempool.
- raw_
transaction_ πby_ txid - Fetches a mined transaction from the best chain by its transaction ID.
- rpc_
arg_ πerror_ to_ status - Converts a JSON-RPC method error into a gRPC status, for a call whose arguments the client supplied and Zebra has not already validated.
- rpc_
error_ πto_ status - Converts a JSON-RPC method error into a gRPC status, for a lookup of something the client asked for by identifier.
- send_
bounded π - Sends
itemto a response stream, returning false if the client disconnected or stopped reading. - send_
raw_ πmempool_ tx - Sends a mempool transaction to a raw transaction stream, returning false if the client disconnected or hung, or the transaction could not be serialized.
- send_
unseen_ πmempool_ txs - Sends every mempool transaction that isnβt already in
sent_txids, adding the ones it sends, and returns false if the client went away or the mempool query failed. - serialize_
transaction π - Serializes a transaction into raw bytes for a
RawTransaction. - taddress_
transactions_ πstream - Returns a stream of raw transactions for the given transparent address and block range, in block order.
- treestate_
to_ πproto - Converts a
GetTreestateResponseinto a lightwalletdTreeState.
Type AliasesΒ§
- Response
Stream π - A type alias for the boxed response streams returned by server-streaming methods.