Green Proofs Software Stack

The following are the most important libraries in the core Green Proofs software development kit:

  • Worker Node Package: The worker node package is responsible for deploying the off-chain logic execution / verification node in the Green Proof application network. This base layer package includes the logic to send votes to voting smart contract, contain the plug-in API system, and operate more specialised logic execution packages such as the 24/7 matching logic package.

  • Overseer Node Package: The overseer node is responsible for reading the notarised merkle tree hash result from the Energy Web Chain and relay this back to the DDHub to be cached and retrieved by the reporting back-end.

  • Voting Contract Package: This package contains solidity smart contract deployed on EWC.

  • GP Merkle Tree Package: This package is a wrapper around merkletreejs, and can be used to create unified merkle trees. For Green Proof solution, the Worker nodes calculate the merkle tree root hash from their logic execution result, and submit this to the voting contract.

  • Issuance Contract Package: In development

  • Core Reporting Cache: TBD not finalised, the reporting cache package is responsible for caching data from the chain, so that the Proof Reporting Tool can query and effectively generate proofs.

  • Postgres: Used for the back-end database storage. Industry-standard relational SQL-compliant database that is used for most of the off-chain data.

  • Kysely: a type-safe and autocompletion-friendly typescript SQL query builder. Inspired by knex. Mainly developed for node.js but also runs on deno and in the browser. Used to query Postgres DB.

  • Nest.JS: Nest (NestJS) is a framework for building efficient, scalable Node.js server-side applications. It uses progressive JavaScript, is built with and fully supports TypeScript (yet still enables developers to code in pure JavaScript) and combines elements of OOP (Object Oriented Programming), FP (Functional Programming), and FRP (Functional Reactive Programming). Under the hood, Nest makes use of robust HTTP Server frameworks like Express (the default) and optionally can be configured to use Fastify as well.

Last updated