Basic idea
TPScore simplifies TPS Data Analysis for non-technical users in the Polkadot Ecosystem.
TPScore aims to provide non-technical users in the Polkadot ecosystem with an accessible and user-friendly platform for analyzing TPS (Transactions per Second) data. Our goal is to bridge the gap between technical intricacies and user-friendly visualization, empowering individuals to make informed decisions about blockchain adoption, investment, and development.
How it was build
The project was build for the Web3 Foundation Grants Program. TPScore consists of two main parts:
ETL System
We retrieve blockchain data using either the Subscan API or connect to the public endpoints of parachains using the Substrate interface library. Also we use Apache Airflow to ensure streamlined data processing.
To calculate the average TPS, we take the number of transactions within the last 100 blocks. We fetch raw data at regular intervals of every 10 minutes. This raw data then undergoes processing within Airflow's DAGs using Python Operators, ensuring efficient data transformation and preparation. Finally, the processed data is stored in a MySQL database.
User Interface
We use Next.js as our full-stack framework. It allows to both retrieve data from the MySQL database and render React app on a server.
To visualize data, we use a simple and concise UI: the grid of cards with the blockchain's name and TPS. We expect one common use case: users go to our website and scan through all chains to find a desired one. So we simplify this process by adding handy sorting and searching functionality.
How to use it
Go to tpscore.xyz and grasp real-time transactions per second metrics for the desired blockchain in Polkadot ecosystem.
How to contribute
We provide detailed guide for both ETL System and User Interface. You can easily spin up local development setup with Docker by following simple steps from READMEs. Also we provide inline documentation for you. Core logic is fully covered by unit tests, so you can contribute without fear of breaking anything.
Top comments (0)