Skip to content
All use cases
Solutions

Solana shred feeds for analytics platforms

A latency budget for converting raw Solana shreds into provisional market metrics while preserving forks, gaps, and later corrections.

Where the milliseconds go

StageBudgetNotes
Detection0.3 to 1.2 msClassify transactions into subscribed programs, assets, pools, and metric streams.
Decode0.8 to 5.0 msReconstruct entries, resolve accounts, and parse supported economic events.
Decision0.5 to 3.0 msApply metric rules, confidence labels, deduplication, and provisional aggregation.
Signing0 to 0.2 msNo signature is needed unless the publisher signs outbound batches.
Submission1 to 15 msPublish a bounded batch to streaming clients or a serving log.
Land0.4 to 13 sRevise the metric when its source transactions reach the selected commitment.

6 stages separate freshness from certainty

An analytics platform turns transactions into prices, volumes, flows, liquidity measures, alerts, and charts. A shred feed can start that transformation before a completed block reaches normal interfaces. The first published metric is provisional because its source block is provisional.

For an analytics platform, the complete Frankfurt stream lands as raw UDP on its chosen IP and port before any metric filter runs. A $100 payment keeps that destination active for 30 days. Because no published standalone offer costs less, a high-volume platform carries no metered feed-bandwidth bill.

Low-latency analytics is valuable for machine clients, risk monitors, and live market views. It is dangerous when an API removes the qualifiers that make early data accurate. Freshness and commitment need separate fields, service levels, and user language.

Shreds show proposed execution

Without a public Solana mempool, analytics begins with transaction bytes the leader has already placed into its candidate block. They arrive ahead of ordinary processed or confirmed interfaces, but they do not represent future intent. Each resulting metric describes provisional activity seen by that platform.

The source transaction may fail. Its slot may be skipped. Its fork may lose. Another transaction later within that slot could reverse the price move. Analytics built from an entry prefix should never be labeled final block analytics.

A clean model has observed, processed, confirmed, and finalized views. Clients can choose. Streaming consumers receive status updates or retractions. Historical endpoints default to a documented commitment rather than silently mixing stages.

Fields turn bytes into market events

Analytics sequence combines the slot and shred index with each entry's position and its transaction's position. Price paths and volume windows depend on this ordering. Variant plus FEC-set identity preserves recovery provenance. Completion flags show whether an entry range or the slot is complete.

Leader signature validates proposed source. Shred version selects the decoder. Program IDs combined with account keys map instructions onto venues, pools, mints, vaults, and known entities. Instruction data supplies direction, limits, deposits, withdrawals, borrows, repayments, and other supported semantics.

Token balances and economic transfers are not always stated in one instruction. Multi-program transactions can wrap SOL, route through several pools, create accounts, and close accounts. A correct parser needs protocol-specific rules, and some metrics require later execution output. The fast path should publish only metrics it can derive from the available state.

Transaction signature is the event identity for deduplication and commitment reconciliation. Arrival, entry-ready, decoded, aggregated, and published timestamps show where freshness was spent. A single timestamp named time conceals too much.

Budget time from ingest to publication

StageTargetWhat the number assumes
Detection0.3 to 1.2 msFixed account and program maps classify subscribed activity in batches.
Decode0.8 to 5.0 msRequired shreds and lookup data are local, with bounded recovery.
Decision0.5 to 3.0 msMetric definitions and provisional aggregation state are memory resident.
Signing0 to 0.2 msPublishing normally needs no signature; an optional batch signature is amortized.
Submission1 to 15 msA local serving log or fanout publishes bounded batches without slow-client feedback.
Land0.4 to 13 sLater observations move the source event through chain commitment levels.

From detection through publication, the five local stages add to 2.6 through 24.4 milliseconds. This range describes required-byte arrival through availability on a low-latency serving stream. It excludes leader-to-Frankfurt propagation, travel to the receiver, and later commitment.

Detection is subscription classification. Decode is the expensive stage because bytes become entries, transactions, resolved account keys, and supported events. Decision applies metric rules and confidence. Signing is zero for an ordinary unsigned API. Submission means publish to the platform's serving layer. Land means the source event reaches a stated chain commitment, which the platform observes but does not cause.

These definitions prevent a category error. An analytics service does not sign or land the observed transaction. It may sign a data batch, and it may wait for the chain. The table preserves the requested six-stage frame while stating which stages differ from trading.

Work a provisional price example

Assume a decoded swap sends 50 SOL into a supported constant-product pool and receives 4,900 token units. The direct execution ratio is 50 divided by 4,900, or about 0.010204 SOL per token before separating fees and route effects.

The platform verifies that the accounts match the registered pool, identifies input and output mints, applies decimals, and checks whether the transaction contains another swap leg. If this is the only relevant leg, it publishes a provisional trade with source slot, signature, sequence, amount, derived price, parser version, and observed commitment.

A one-minute volume aggregate adds 50 SOL and 4,900 tokens at observed status. When the transaction becomes confirmed, the platform moves its contribution from observed to confirmed without adding it again. If the fork loses, it subtracts the observed contribution and emits a retraction.

An all-commitment chart that adds on observation and never retracts will overstate volume. A confirmed-only chart can remain stable but arrives later. Both are valid products when labeled.

Price is a method, not one division

Pool trades can include fees, transfer-fee tokens, exact-input or exact-output limits, multi-hop routes, and inner instructions. Reserve changes may include deposits or protocol fees unrelated to the displayed trade. A platform should document whether price comes from instruction amounts, token balance deltas, reserve deltas, or a later execution trace.

Volume should exclude self-transfers and avoid double-counting route legs according to a published rule. Liquidity can mean reserve value, executable depth within a percentage, or total deposited value. Market capitalization can use circulating supply, total supply, or another definition. Early delivery does not resolve ambiguous metrics.

Method version belongs in the data. If a parser correction changes volume, historical rows should identify which calculation produced them. Backfills must not silently blend old and new semantics.

Slow clients cannot slow UDP

Raw UDP provides no backpressure. Neither should one analytics websocket. The receive pipeline, decode pipeline, aggregation log, and client fanout need separate bounded queues. Slow clients can be disconnected or moved to snapshots plus deltas under a documented rule.

If client fanout shares a process queue with decode, a popular dashboard can cause packet loss. Persist or publish into an independent log before serving broad queries. Record queue age at every boundary. A low packet-arrival timestamp is meaningless when the event waits 500 milliseconds in aggregation.

Aggregation batches exchange some freshness for throughput. A one-millisecond window may reduce publish calls while staying inside the budget. A 100-millisecond window may suit human charts but not machine alerts. Expose different products rather than one hidden compromise.

Loss and recovery affect metric confidence

UDP has no ordering or retransmission. Duplicate shreds and missing indexes are expected receiver conditions. Use FEC coding shreds for recovery when possible. Mark unrecovered ranges and prevent incomplete state from appearing complete.

Busy packet periods reward batched system calls and reused memory. Monitor interface drops, kernel socket-buffer errors, application drops, gaps, recovery duration, decode errors, parser quarantine, aggregate lag, and publish lag. Store enough raw provenance to reproduce disputed metrics.

Analytics source filtering keys on 203.23.178.228 exclusively. At the receiver's selected UDP socket, admit that sender and reject unexpected traffic under local policy. The 600-second challenge checks reachability before activation, not sustained throughput or event completeness.

Freshness needs named clocks

Report receiver arrival to publish latency separately from estimated chain event time to receiver arrival. The latter requires trustworthy timestamps at different locations and is harder to measure. Clock synchronization error can exceed an attractive sub-millisecond claim.

Measure local intervals on a monotonic clock. Cross-host joins instead require synchronized wall time. Record whether each timestamp came from the kernel, receive loop, decoder, or publisher, then publish percentiles and sample counts over a dated window.

An API can expose source_slot, commitment, observed_at, decoded_at, published_at, parser_version, and completeness. Clients then decide whether a 15-millisecond observed metric or a later confirmed metric fits their use.

Product analytics must admit corrections

Human interfaces should show a provisional marker without turning every fork event into noise. Machine streams need explicit update and retract event types. Cache keys must include commitment. Alerts should state whether they fired on observed or confirmed state.

Billing, compliance, and customer statements should use the required canonical commitment, not the fastest view. Research can store every branch. Trading dashboards may prefer observed state with visible confidence. One data pipeline can support all three only when it retains provenance.

Do not infer transaction intent from account labels alone. A known exchange address can handle internal operations. A large transfer can be collateral movement rather than a sale. Labels need sources, capture dates, and confidence separate from shred facts.

Build live analytics from the first observable bytes

Raw shreds give live products the first observable bytes for machine clients, risk monitors, alerts, and market views. The platform publishes provisional state quickly, then reconciles it as commitment advances.

The platform's chosen network socket receives the Frankfurt stream. Packets arrive as raw UDP. The analytics wire orders nothing, retransmits nothing, and applies no backpressure; it also supplies neither historical API nor regional redundancy. Build ingest, recovery, storage, and distribution around those properties.

Acceptance needs a correction test

Run the provisional stream beside a confirmed reference for a representative busy window. For every supported event, compare signature, slot, transaction order, success status, account mapping, amounts, and derived metric contribution. Count false positives, missing events, retractions, parser quarantines, and differences caused by method rather than transport.

Inject a losing fork into replay. The observed stream should publish it under provisional status, the confirmed view should exclude it, and clients should receive a deterministic retraction. Restart the publisher between observation and retraction to prove that correction state survives process failure.

Measure freshness from kernel arrival through client receipt, using a timestamp at the consuming side. Server publication alone omits queueing and fanout. Publish the median, p95, p99, worst observation, sample total, and recovery share. Segment results by program because one expensive parser can distort a global percentile.

Set an error budget for incomplete input. A platform might require 99.99 percent of supported canonical events to appear in its confirmed stream during the window, while permitting a documented provisional retraction rate. The exact target belongs to the operator. Publishing it makes the trade between speed and correction visible.

Finally, force a slow client, a full disk, a parser exception, and a burst above the expected rate. Packet receive must stay live or enter an explicit degraded state. An analytics platform is ready when failure changes a visible confidence label, not when every happy-path chart updates quickly.

Required bytes can become a provisional metric in roughly 3 to 24 milliseconds inside a prepared platform. Commitment still takes chain time. Accuracy comes from preserving the distinction.

What this desk reads

  • slot, shred index, and transaction order, to calculate ordered provisional market events
  • FEC set index and completion state, to label recovered or incomplete data
  • leader signature and shred version, to authenticate and parse the proposed input
  • program and account identifiers, to map events onto assets, pools, venues, and entities
  • instruction data and token amounts, to calculate price, volume, liquidity, and flow under supported programs
  • transaction signature, to deduplicate events and retract or confirm their contribution
  • arrival, decode, and publish timestamps, to state freshness without conflating it with finality

Questions

Can an analytics platform publish shred-derived metrics as final?
No. Transactions decoded from shreds belong to proposed blocks. A platform can initially mark them observed or provisional, then update, confirm, or retract their contribution as the chain advances. Historical, billing, and compliance views should use the documented commitment appropriate to those products.
Why is the signing stage zero for most analytics platforms?
An analytics publisher usually sends data to its own clients rather than signing an on-chain transaction. It may sign batches for authenticity, but that work can be amortized outside packet receive. Reporting a zero lower bound makes the different meaning explicit instead of inventing work that does not occur.
What timestamp should a low-latency analytics API expose?
Expose at least receiver arrival, decode completion, publish time, source slot, and commitment. Local intervals belong on monotonic clocks; comparing hosts requires synchronized wall clocks. A single event time cannot distinguish network arrival, processing delay, API delay, and later chain acceptance of the source transaction.