-
Notifications
You must be signed in to change notification settings - Fork 81
Description
Overview
This issue involves reviewing all event definitions within the LandRegistry smart contract and implementing an enhanced indexer service. The indexer should listen for all relevant events, capture them in real-time, and store them in a structured Postgres database. Additionally, endpoints (or GraphQL schema) should be provided to allow client applications to query the indexed event data.
Background
📜 The LandVer protocol utilizes blockchain events to manage land registration and verification. Ensuring that all events are correctly indexed and easily queryable is crucial for a robust off-chain view of on-chain transactions. This work builds upon the existing indexer service within the land-registry-indexer directory, with improvements to performance, data structure, and documentation. More details on project structure can be found in the README.
Requirements
-
Event Review & Indexing
- Review and verify all event definitions in the LandRegistry smart contract.
- Ensure every relevant event is captured by the indexer.
-
Real-time Data Synchronization
- Implement an indexer that listens for smart contract events and syncs them in real-time.
-
Database Storage
- Store captured event data into a structured Postgres database.
- Align the database schema with the client application’s data requirements.
-
Query Interface
- Provide endpoints (or a GraphQL schema) for querying the indexed event data.
- Ensure the API is robust and can handle dynamic data queries.
-
Cleanup & Documentation
- Remove or archive any outdated/stale components from previous indexer implementations.
- Produce setup scripts for the Postgres schema and indexing service.
- Update documentation detailing the indexer workflow and how to query the event data.
Definition of Done
- All relevant contract events are successfully captured by the indexer and stored in Postgres 🔍
- Indexed event data is accessible via the provided query interface (endpoints or GraphQL) 🌐
- The indexer service is running in real-time and synchronizes with the blockchain events 🚀
- Outdated components from the previous indexer are removed or archived 🧹
- Updated documentation and setup scripts are available, ensuring maintainability and ease of onboarding 📖
Technical Considerations
- Ensure the Postgres schema is optimized for the data needs of LandVer’s client applications.
- Consider scalability and error handling for real-time event processing.
- Validate that the entire solution aligns with existing project architecture and deployment procedures.
Let's work together on making the background event indexing robust and maintainable! 😊