Data infrastructure3 min read

Materialised Views for Blockchain Dashboards

Use precomputed blockchain summaries with explicit refresh and correction policies, while preserving links back to accepted event evidence.

Editorial illustration accompanying materialised views for blockchain dashboards.

Overview

When translating these concepts into an integration, keep the scope described by the wallet history api with the result. The examples in wallet transaction history and smart contract event logs show how the same distinction affects neighbouring data questions.

A materialised view stores a derived query result for faster reads. Its usefulness depends on refresh semantics and its ability to reflect corrections, not only on dashboard latency.

Declare the view contract

State the event grain, included range, accepted-chain policy and refresh time. A view can be current through one block while the chain head has advanced. Keep that covered-through reference with the summary. A refreshed view does not automatically become complete if its input scan had gaps.

Worked example: a corrected daily total

A daily volume summary includes an event later displaced by a reorganisation. Refreshing only newly appended rows leaves the old total wrong. The correction policy must identify and rebuild affected windows or apply a proven reversible adjustment, preserving the relationship to original evidence.

Test freshness and rebuilds

Include late events, decoder changes and a failed refresh. Serve the previous view only with a clear age or coverage indicator under the product policy. Compare rebuilt results with incremental results on the same evidence set. Keep summary identity separate from event identity so consumers do not treat a revised total as new activity.

A practical acceptance test

Build a summary, add a late event and invalidate an earlier source event. Compare incremental repair with a full rebuild over the same accepted evidence. Simulate a failed refresh and retain a clear covered-through reference. The previous summary can remain available under policy, but must not be relabelled current simply because the read endpoint responds quickly.

Questions about the topic

Frequently asked questions

Is a materialised view always current?

No. It reflects its last successful refresh and input coverage.

Can append-only updates miss corrections?

Yes. Historical changes need an explicit repair strategy.

Standards & technical documentation

Further reading

{{TODO: author name}}

Practical explanations of blockchain data, software integration and the context behind a record.

About Indexbase
← Back to all articles

Build with better context.

Get an update when private beta opens.

Form setup in progress. Nothing entered here is sent or saved. {{TODO: endpoint}} See the full form and email alternative.