Performance Decision Model

Disclaimer: This is a summary of patterns we have observed during our research and should not be considered any form of technical or investment advice. Also, the given “known examples” do not imply they are the best implementations of the said pattern or any superior to any other implementation of the pattern not listed.

The patterns covered in this section are designed to deal with big data used in blockchain-based applications. From the four Vs of big data, the performance patterns on blockchain mainly target high volume data (both a datum that is large and massive collection of data). The graphical presentation of the related decision model is shown below.

Decision model for on-chain data management and performance

Decision model for on-chain data management and performance

 

Depending on the data size or volume, patterns on different layers could be considered. For example, if a datum is larger than the transaction size, the hash on-chain (aka., blockchain anchor) pattern at the application layer could be used to store a cryptographic representation of the data (e.g., hash value) on blockchain to prove its off-chain existence. To further improve scalability and support high data volume (where the existence of every piece of data within a data collection needs to be verified), more complex hash-based data structures such as a Merkle tree can be used with Merkle tree root on-chain pattern. This pattern complements the hash on-chain pattern.

Another pattern to manage a large collection of data is state aggregation, which aggregates a set of states into a single or small subset of states. For example, in blockchain data migration/swap, the closing balance of a set of accounts can be migrated/swapped rather than the balance of individual accounts. However, this pattern is constrained by the data type to be aggregated. State channel only records the final settled transaction on the blockchain while handling all intermediate transactions of small monetary value off-chain in a payment channel. Because the raw data is off-chain in these patterns, data can be changed without authorization affecting the integrity.