pub struct SubscribeOptions {
pub categories: u32,
pub from_cursor: Option<Cursor>,
pub since_seq: Option<u64>,
pub tweak_dust_limit: Option<u64>,
pub tweaks_only: bool,
pub mempool_tweaks: bool,
pub tweak_outputs: bool,
pub tweak_unspent_only: bool,
}Expand description
Options for a StreamClient::subscribe firehose.
Fields§
§categories: u32Category bitfield; 0 = all. See Categories.
from_cursor: Option<Cursor>Durable replay anchor. When set, the server replays confirmed history forward from this cursor, then joins live with no gap or duplicate.
since_seq: Option<u64>Forward-only dedup filter: drop events with seq <= since_seq. Use after
a brief reconnect within the broadcast window — not for durable replay.
tweak_dust_limit: Option<u64>Silent-payment tweak dust floor (satoshis): drop TweakEntry
whose max_value is below this, and flag the block filtered. Only
meaningful with the TWEAKS category. None = keep
every tweak.
tweaks_only: boolCompact tweak form: when true, tweak entries carry only the 33-byte
tweak (no txid/max_value), minimizing bytes for a pure client-side
scan. Only meaningful with the TWEAKS category.
mempool_tweaks: boolMempool-time tweaks (“Tier 1.5”): when true, the server additionally
streams an Event::MempoolTweak at each
SP-eligible transaction’s admission, for mempool-latency detection without
uploading a scan key. A modifier on the TWEAKS
category — the server rejects it if that bit is not set. false (default)
= block tweaks only. Ephemeral and best-effort: mempool tweaks are not
replayable, so a missed admission is caught at confirmation via
Event::BlockTweaks.
tweak_outputs: boolInclude the transaction’s taproot outputs on each
Event::BlockTweaks entry
(TweakEntry::taproot_outputs), so
a match is confirmed against the on-chain output without fetching the
block. false (default) keeps the confirmed firehose lean. A modifier on
the TWEAKS category — the server rejects it if that
bit is not set, or if the node has no block source. A
MempoolTweak carries its outputs
regardless of this flag.
tweak_unspent_only: boolCut-through: drop Event::BlockTweaks
entries whose taproot outputs are all already spent on the confirmed
chain. A balance scan then never runs ECDH against a coin that is already
gone. A surviving entry carries its full taproot output set —
spentness decides whether an entry survives, never which outputs it
carries, so BIP 352 k enumeration is never truncated.
A restore that needs transaction history must leave this false: a
payment received and later spent is omitted entirely, so the balance is
right and the history is not. Spentness is evaluated at serve time, so the
same historical block can yield fewer entries on a later scan. Dropped
entries set the block’s filtered flag. A modifier on the
TWEAKS category — the server rejects it without
that bit, or on a node with no block source. Never applies to
MempoolTweak.
Trait Implementations§
Source§impl Clone for SubscribeOptions
impl Clone for SubscribeOptions
Source§impl Debug for SubscribeOptions
impl Debug for SubscribeOptions
Auto Trait Implementations§
impl Freeze for SubscribeOptions
impl RefUnwindSafe for SubscribeOptions
impl Send for SubscribeOptions
impl Sync for SubscribeOptions
impl Unpin for SubscribeOptions
impl UnsafeUnpin for SubscribeOptions
impl UnwindSafe for SubscribeOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request