masa-finance / masa-oracle

Masa Oracle: Decentralized Data Protocol 🌐
https://developers.masa.ai/docs/masa-protocol/welcome
MIT License
24 stars 19 forks source link

Spike: investigate Cosmos SDK #595

Closed mudler closed 2 weeks ago

mudler commented 1 month ago

Problem

We need to have a production ready blockchain that can be used for the following:

  1. Have MASA as native asset for paying for transactions
  2. Enable staking by Validators to secure the network
  3. Enable delegation of stake by Miners to Validators
  4. Enable the deployment of other tokens on our network
  5. Enables the storage of a shared state - for example nodeData
  6. Enables a trusted party (a Validator) to attest and allow non-validators to join the network
  7. May simplify our architecture

We have cards that already capture part of the issues that we want to tackle:

https://github.com/masa-finance/masa-oracle/issues/590 https://github.com/masa-finance/masa-oracle/issues/507 https://github.com/masa-finance/masa-oracle/issues/518 https://github.com/masa-finance/masa-oracle/issues/496 https://github.com/masa-finance/masa-oracle/issues/382 https://github.com/masa-finance/masa-oracle/issues/381

Description

This card is about investigating if we can use the Cosmos SDK to implement Blockchain, CAS and consensus being the nodes and allow to have token with proof of work.

Acceptance criteria

The objective of this card is to make sure that Cosmos SDK can cover the features described in the cards listed above and to which extent. We want to know if its a viable solution to tackle most of the issues instead of backing our own solution on top of libp2p.

restevens402 commented 3 weeks ago

Spike Outcome: Cosmos SDK with Oracle Node Integration

After conducting a spike to evaluate Cosmos SDK for our Oracle Node, we’ve confirmed that Cosmos SDK offers a robust framework for implementing a production-ready blockchain that aligns with our key requirements. We successfully set up a Cosmos-based chain and created a custom module that enables on-chain data storage using Cosmos’ consensus model, demonstrating its suitability for our needs.

1. Native Asset (MASA) for Transaction Fees

2. Staking for Network Security (Validators)

3. Delegation of Stake by Miners to Validators

4. Deployment of Additional Tokens on the Network

5. Shared State Storage (e.g., nodeData)

6. Validator Attestation for Network Entry (Trusted Party Authorization)

7. Simplified Architecture Compared to libp2p (Hybrid Approach)

Next Steps:

mudler commented 2 weeks ago

Closing with the https://github.com/masa-finance/masa-oracle/issues/619 as follow-up.

Outcome: We know that Cosmos SDK is having all the features we need for having our own blockchain and token, but we want to make sure before jumping into it, to not loose all the benefits of using a libp2p-based transport layer, and go back at a "web2" style of network.