[Periodic Report] Event Based Architecture #2

Project Name

Event Based Architecture

Report Period

January 21st - February 22nd

Report Description

Over the last month we put together all the components of the API infrastructure and have verified it’s functionality. We now have basic REST, websockets, and a GraphQL endpoints built along with a custom event registration and broadcasting framework. The entire stack is deployed via a docker-compose with various override files to allow different features and settings. Each component of the stack is built from individual microservices that perform different functions such as registering events, processing events, and exposing each of the individual APIs.

The main repo can be found at github.com/geometry-labs/icon-api with the underlying containers found in the following table.

Name Description
etl Icon etl to scan the blockchain and pipe data to kafka brokers
registration Rest api to register contracts and transactions to track
filter-worker-contract Filter worker for contracts
filter-worker-transaction Filter worker for transactions
rest-api Rest api to retrieve historical icon blockchain data
kafka-websocket-server Websocket server to stream live data for blocks, transactions, and contract logs
kafka-topic-init Kafka topic initialization container, exit 0 after completion
kafka-connect-init Kafka contract initialization container, exit 0 after completion

Project Completion Percentage

~80%

Remaining Time to Completion

1 months

Expected Results for the Next Period

While the vast majority of the development is done with test coverage running in github actions, we still have a few more items to finalize the project before submission. These items include:

  • Endpoint mappings
    • We’re using Traefik as a reverse proxy which will give us path routing to all the services.
  • Full Chain Sync
    • We plan on syncing up the entire chain from genesis to validate any parsing errors.
  • API Docs
    • The REST APIs are self documented with an OpenAPI spec and are exposed at a /docs endpoint. Other services such as Websockets and GraphQL will be documented in markdown.
  • Demos
    • We will be showing this tool off to members of the community to stir up interest in it’s use and talk about use cases it can be employed in.
  • Tutorial
    • We will be writing a short tutorial on how to use the various components of the stack.