Technical Architecture

This article aims to provide a high-level overview of the technical architecture behind Upstream.

Upstream utilizes an intricate blend of on-chain and off-chain technologies to build a platform that promotes the efficient operation of DAOs, with a specific focus on reducing the necessity for gas fees.

Server Structure

The Upstream infrastructure revolves around four primary servers:

  1. Website Server: Hosted on AWS, this server is responsible for delivering the frontend of the Upstream platform.

  2. API Servers: Also hosted on AWS, these servers manage the back-and-forth communication with the client, serving data requested by the website.

  3. Blockchain Listener: This server's primary function is to monitor events on the blockchain.

Event Listening and Fortuna

With our DAO contract's evolution, we're currently listening to over 15 event types, including EnableDepositsChanged, EnableWithdrawsChanged, GateDepositsChanged, and ExchangeRateChanged. To handle this complexity, we built an in-house service, "Fortuna," which captures and maps these events to our database.

Proxy Contracts and Upgrades

Another critical aspect of our architecture is the use of proxy contracts. Once a contract is launched, it cannot be updated. However, upgradable contracts, or "proxies," provide a workaround.

Contract Types

Upstream launches three primary contracts to the blockchain:

  1. DAO Contract: A large contract, which is responsible for maintaining feature flags, managing deposits and withdrawals, and more.

  2. Vote Delegation Contract: This contract, maps who has delegated voting rights to whom. This contract remains on the blockchain for transparency.

  3. Gnosis Wallet Contract: This contract grants the ability to execute actions and is part of every DAO to support multi-signatures.

Supported DAOs

Upstream currently supports two types of DAOs:

  1. New Contract: DAOs that wish to launch their own token.

  2. Existing Contract: DAOs with tokens already available on the market.

We facilitate the launch of an "External Token Contract" that doesn't issue a token but still offers DAO functionalities. We also support the creation of ERC20 tokens.

In summary, the architecture of Upstream is an intricate balance of on-chain and off-chain technologies, aiming to reduce gas fees and create a seamless, efficient platform for DAOs. It's important to remember that this design is not static - we're constantly seeking ways to improve our system for better performance and user experience.

Last updated