IceFireDB and IceGiant BaaS Speech CN

Page1:introduce

很高兴见到大家,我来自IceFireLabs,我们正在进行一些web3领域的项目,其中包括IceFireDB、IceGiant和FlowShield。这些项目主要关注数据存储和网络安全方向。现在我将详细介绍一下我们的web3数据库项目情况。

Nice to meet you all, I come from IceFireLabs, and we are working on some projects in the field of web3, including IceFireDB, IceGiant and FlowShield. These projects mainly focus on data storage and network security. Now I will introduce our web3 database project in detail.

Page2: Outline description

今天,我将主要围绕三个方面进行阐述。首先,我会介绍存储领域web3存储领域的趋势和问题。其次,我会详细介绍IceFireDB的存储堆栈,包括其核心分层和重要组成部分。最后,我会介绍IceGiant BaaS,可帮助去中心化数据库实现链上数据价值。

Today, I will focus on three aspects. First of all, I will introduce the trends and problems in the storage field of web3. Secondly, I will introduce the storage stack of IceFireDB in detail, including its core layering and important components.Finally, I will introduce IceGiant BaaS, which can help decentralized databases realize the value of data on the chain.

Page3: Trend & Problem

为什么我们需要去中心化存储和数据库,我们先介绍一些背景。

Why do we need decentralized storage and decentralized databases, Let's introduce some background first.

Page4:Why do we need decentralized storage?

云存储改变了在线存储和文件共享的使用方式,但中心化管理会导致权限和文件丢失问题,大公司控制数据,停机也是个问题。去中心化存储解决了数据隐私和所属权问题,分布式系统能够管理大规模中心数据,云服务采用Spanner、TiDB等解决方案。分布式不一定是去中心化,但去中心化系统总是分布式的。Filecoin和Storj等分散式解决方案将数据分块存储在全球多个节点上,创建多个拷贝,提高数据恢复能力。

Cloud storage has changed the way online storage and file sharing are used, but centralized management can lead to permissions and file loss issues, large companies control data, and downtime is also a problem.

Decentralized storage solves data privacy and ownership issues, distributed systems can manage large-scale central data, and cloud services use solutions such as Spanner and TiDB. Distributed is not necessarily decentralized, but a decentralized system is always distributed. Decentralized solutions such as Filecoin and Storj store data in blocks on multiple nodes around the world, creating multiple copies and improving data recovery capabilities.

Page5: The Architecture of Decentralized Storage

为了实现完全去中心化的应用程序,需要将去中心化数据库纳入Web3应用程序堆栈中。应用程序堆栈由智能合约层、文件存储、数据库和通用基础设施层组成。去中心化的文件存储和数据库网络在Web3应用程序中扮演重要角色,提供存储结构化和非结构化数据的基础设施,这是所有应用程序的共同需求。

In order to realize a full decentralized application, it is necessary to bring the decentralized database into the Web3 application stack. The application stack consists of smart contract layer, file storage, database and other infrastructure layer.

Decentralized file storage and database networks play an important role in Web3 applications, providing the infrastructure to store structured and unstructured data, which is a common requirement of all applications.

Page6: Decentralized File Storage Networks (DFSNs)

Filecoin和Arweave等分散式文件存储网络主要用于去中心化存储非结构化数据,如文本、图像、音频和视频等。与此不同,去中心化数据库项目主要用于存储有预定义格式的数据,如NoSQL、SQL和Graph协议的数据。

Distributed file storage networks such as Filecoin and Arweave are mainly used for decentralized storage of not predefined data, such as text, images, audio and video. Unlike this, decentralized database projects are mainly used to store data with predefined formats, such as NoSQL, SQL and Graph protocols.

Page7: Decentralization lacks data expression layer and database

这个表格包含了一些web3数据库,它们具有不同的数据模型、网络架构、数据验证和访问控制。IceFireDB是一个多模型数据库,支持键值和SQL模型,同时支持分布式或去中心化网络,如RAFT、P2P、CRDT和IPFS日志。它的web3网络层连接到IceGiant的POS区块链,并通过与IceGiant的交互实现数据库数据的所属权控制。
This table includes some web3 databases with different data models, network architecture, data validation and access control.

IceFireDB is a multi-model database that supports key-value and SQL models, while supporting distributed or decentralized networks such as RAFT, P2P, CRDT, and IPFS logs. Its web3 network layer is connected to IceGiant's POS blockchain, and through the interaction with IceGiant, ownership control of database data is realized.

Page8:The value of web3 databases

web3数据库填补了web3存储领域的一个空白,为Web3应用提供了可编程的数据网络,简化了数据访问和应用构建。它们帮助数据构建价值,并允许用户在链上生产和消费数据,构建数据的经济价值。web3数据库具备模块化和扩展能力,允许在应用中组合数据键或表。结合区块链和去中心化网络结构,数据库网络能够快速扩展以满足大量的数据存储和读取需求。同时,web3数据库通过暴露区块链的RPC实现链上和跨链交互,具备很好的数据交互能力。

The web3 database fills a gap in the web3 storage space, provides a programmable data network for Web3 applications, and simplifies data access and application construction. They help data build value, and allow users to produce and consume data on the chain, building the economic value of data.The web3 database is modular and extensible, allowing data keys or tables to be combined in applications. Combining the blockchain and decentralized network structure, the database network can quickly expand to meet a large amount of data storage and reading needs.At the same time, the web3 database realizes on-chain and cross-chain interactions by exposing the RPC of the blockchain, and has very good data interaction capabilities.

Page9:IceFireDB Stack

IceFireDB Stack包含去中心化数据库引擎、去中心化网络库和去中心化生态组件。其旨在使用户应用更轻松地接入去中心化网络,尤其是去中心化数据网络。

IceFireDB Stack includes decentralized database engine, decentralized network library and decentralized ecological components. It aims to make it easier for user applications to access decentralized networks, especially decentralized data networks.

Page10:IceFireDB helps applications achieve data decentralization

在当今的数据中心化情况下,将现有的大规模Web2应用转变为完全去中心化的数据存储很困难。在Web3世界中,还没有能够轻松且完全去中心化地构建应用程序的方法。传统的去中心化存储协议如Filecoin主要用于文件存储,无法提供强大的数据库级数据表达能力。IceFireDB采用libp2p、crdt和ipfs-log构建分布式及去中心化网络,并构建丰富的NoSQL、SQL数据结构。结合IceGiant区块链能力,它可以成为数据去中心化的桥梁,帮助构建彻底去中心化的Web3应用程序。使用IceFireDB,Web2应用程序无需修改代码即可实现、可信、去中心化数据存储的转变。

In today's data centralization situation, it is difficult to transform existing large-scale Web2 applications into fully decentralized data storage.

In the Web3 world, there is no way to build applications easily and fully decentralized.

Traditional decentralized storage protocols such as Filecoin are mainly used for file storage and cannot provide powerful database-level data expression capabilities.

IceFireDB uses libp2p, crdt and ipfs-log to build a distributed and decentralized network, and builds rich NoSQL and SQL data structures.

Combined with IceGiant blockchain capabilities, it can become a bridge for data decentralization and help build fully decentralized Web3 applications.

With IceFireDB, Web2 applications can transition to trusted, decentralized data storage without code changes.

Page11:Application architecture based on IceFireDB

IceFireDB既适用于Web2应用程序栈,也适用于Web3应用程序。对于Web2应用程序,IceFireDB提供去中心化数据库存储引擎,支持RESP和SQL协议,帮助web2应用程序能够快速接入去中心化数据库能力。而在Web3应用栈中,IceFireDB与IceGiant区块链层进行通信,构建了区块链数据库。因此,IceFireDB在Web2和Web3的应用程序中都可以发挥重要的数据库作用。

IceFireDB is suitable for both Web2 application stacks and Web3 applications. For Web2 applications, IceFireDB provides a decentralized database storage engine, supports RESP and SQL protocols, and helps web2 applications quickly access decentralized database capabilities. In the Web3 application stack, IceFireDB communicates with the IceGiant blockchain layer to build a blockchain database. Therefore, IceFireDB can play an important role as a database in both Web2 and Web3 applications.

Page12: IceFireDB module architecture

IceFireDB由存储层、去中心化数据面、区块链控制面、平台层和生态组件组成。存储层涵盖了分布式和去中心化网络、持久化存储、P2P消息广播、数据编码解码和应用层通信协议。

引擎层构建了去中心化的数据平面,用户可以通过协议通信接口和协议客户端两种方式快速接入和使用。区块链控制面基于cosmos区块链技术,管理去中心化存储节点、处理链上数据读写,并实现数据多租户、可信控制和多链数据操作。

生态组件主要包括集群网络代理、SQL/RESP协议数据读写代理、CRDT/IPFS-LOG去中心化数据共识库以及高性能网络IO框架RedHub。


IceFireDB consists of storage layer, decentralized data plane, blockchain control plane, platform layer and ecological components. The storage layer covers distributed and decentralized networks, persistent storage, P2P message broadcasting, data encoding and decoding, and application layer communication protocols.

The engine layer builds a decentralized data plane, and users can quickly access and use it through the protocol communication interface and the protocol client.

Based on the Cosmos blockchain technology, the blockchain control plane manages decentralized storage nodes, handles data reading and writing on the chain, and realizes multi-tenant data, trusted control and multi-chain data operations.

Ecological components mainly include cluster network proxy, SQL and RESP protocol data read and write proxy, CRDT and IPFS-LOG decentralized data sync library, and high-performance network IO framework RedHub.

Page13:IceFireDB Layer architecture

IceFireDB的系统层次设计包括网络层、存储层、协议层和编解码层。网络层负责集群组网和应用程序的接入。当数据库引擎接收到请求时,它根据协议层的格式要求对请求进行解析和处理。解析后的指令传递给编解码层进行编解码操作,然后传递给存储层。存储层根据存储驱动进行数据的读取和写入工作。这些层级相互配合,实现了IceFireDB的数据库存取能力。

The system level design of IceFireDB includes network layer, storage layer, protocol layer and codec layer. The network layer is responsible for cluster networking and application access. When the database engine receives a request, it parses and processes the request according to the format requirements of the protocol layer. The parsed instructions are passed to the codec layer for codec operations, and then passed to the storage layer. The storage layer reads and writes data according to the storage driver. These levels cooperate with each other to realize the database access capability of IceFireDB.

Page14.IceFireDB network layer

IceFireDB的网络层负责节点间组网、节点间数据广播和节点间数据一致性。它包括两个网络类型:短距离的分布式数据网络和广距离的去中心化数据网络,这两个网络使用不同的技术。在短距离的分布式网络中,IceFireDB使用RAFT共识协议构建集群,在去中心化数据网络中,IceFireDB利用P2P技术进行组网,并使用P2P PubSub通信方式同步数据库操作命令。此外,通过将p2p发布订阅网络与RESP协议和SQL协议进行融合,IceFireDB提供了去中心化的发布和订阅中间件,以支持应用程序的去中心化。为了提升去中心化数据库的状态一致性,IceFireDB在p2p网络基础上结合了IPFS-LOG、CRDT KV技术,增强数据库指令日志广播网络。

The network layer of IceFireDB is responsible for inter-node networking, inter-node data broadcast and inter-node data consistency.It includes two network types: a short-distance distributed data network and a long-distance decentralized data network, which use different technologies.

In a short-distance distributed network, IceFireDB uses the RAFT consensus protocol to build clusters.

In the decentralized data network, IceFireDB uses P2P technology for networking, and uses P2P PubSub communication to sync database operation commands.

In order to improve the state consistency of the decentralized database, IceFireDB combines IPFS LOG and CRDT KV technology on the basis of the p2p network to enhance the broadcast network of the database instruction log.

Page15. IceFireDB storage layer

IceFireDB的存储层负责数据的存储,支持不同的存储底层。对于Web2,支持LevelDB、Badger和OSS;对于Web3,支持IPFS、CRDT-KV、IPFS-LOG和OrbitDB。存储层包括编解码层和数据持久化层。

数据库的存储有两种方式:一种是基于IPFS-LOG、CRDT-KV、OrbitDB的数据库指令广播模型;另一种是基于键值底层存储结构,通过指令编解码方式实现的原生数据存储模式。

IceFireDB在状态广播方面还包括正在建设中的IceGiant,它是位于IceFireDB引擎之上的区块链。IceGiant处理链上数据库请求并与链下的IceFireDB进行互动,实现IceFireDB的数据去中心化,行为和状态的可信性。

The storage layer of IceFireDB is responsible for data storage and supports different storage bottom layers. For Web2, LevelDB, Badger, and OSS are supported; for Web3, IPFS, CRDT-KV, IPFS-LOG, and OrbitDB are supported. The storage layer includes codec layer and data persistence layer.

There are two ways to store the database: one is the database command broadcast model based on IPFS-LOG, CRDT-KV, and OrbitDB; the other is the native data storage mode based on the key-value underlying storage structure and realized by command encoding and decoding.

IceFireDB also includes IceGiant under construction in terms of status broadcasting, which is a blockchain on top of the IceFireDB engine. IceGiant processes on-chain database requests and interacts with off-chain IceFireDB to realize IceFireDB's data decentralization, behavior and state credibility.

Page16.IceFireDB Codec layer

IceFireDB支持更丰富的NoSQL数据指令,与KV模型相比具有更多的应用领域。编解码层是IceFireDB NoSQL的重要组成部分,负责将NoSQL指令改变为底层存储引擎支持的键值对,现在支持如Strings、Hashes、Sets、Lists数据类型。

IceFireDB supports richer NoSQL data instructions and has more application fields than the KV model. The codec layer is an important part of IceFireDB NoSQL, responsible for changing NoSQL instructions into key-value pairs supported by the underlying storage engine, and now supports data types such as Strings, Hashes, Sets, and Lists.

编解码层支持数据指令适配不同的存储引擎,并将存储引擎的KV操作扩展为更多数据指令。

The codec layer supports data instructions to adapt to different storage engines, and extends the KV operation of the storage engine to more data instructions.

P17.IceFireDB Protocol Layer

IceFireDB支持RESP和SQL协议,RESP协议支持IceFireDB-NoSQL与应用通信。RESP协议包括数据控制协议和集群控制协议。数据控制协议用于数据库数据读写,集群控制协议用于管理节点状态和数据分片。IceFireDB通过请求处理周期分析和优化请求流量,实施负载均衡、主从路由和数据缓存等方法提升性能和效率。对于RESP和SQL协议,这些协议的得到大多数计算机语言的SDK支持,这对web2应用改造比较友好。

IceFireDB supports RESP and SQL protocols, and the RESP protocol supports communication between IceFireDB-NoSQL and applications.

The RESP protocol includes a data control protocol and a cluster control protocol. The data control protocol is used to read and write database data, and the cluster control protocol is used to manage node status and data sharding.

For RESP and SQL protocols, these protocols are supported by SDKs of most computer languages, which is more friendly to web2 application transformation.

P18. IceFireDB Ecosystem Components

围绕IceFireDB开源了这些项目,包含IceFirDB NoSQL、IceFireDB SQLite、去中心化数据库代理、去中心化消息发布订阅、高性能IO框架。

These projects have been open sourced around IceFireDB, including IceFirDB NoSQL, IceFireDB SQLite, decentralized database proxy, decentralized message pubsub, and network framework.

P19.IceGiant BaaS

IceFireDB围绕去中心化数据库存储,它不具备数据所有权控制的能力。IceGiant是一个web3区块链数据库协议,目前基于Cosmos区块链构建。IceGiant支持通过区块链进行数据库读写。

IceFireDB around decentralized database storage, which does not have the ability to control data ownership. IceGiant is a web3 blockchain database protocol built on top of the Cosmos blockchain. IceGiant supports database read and write through the blockchain.

P20.ON/OFF-chain mixed state

IceGiant是一个区块链网络,应用程序调用区块链的RPC接口进行数据库的读写。链下部分是IceFireDB数据库引擎,链上链下这两层通过 ABCI 应用区块链接口进行组合。

IceGiant is a blockchain network, and the application program calls the RPC interface of the blockchain to read and write the database. The off-chain part is the IceFireDB database engine, and the two layers on and off the chain are combined through the ABCI application block chain interface.

IceGiant除了具有写入和读取链上数据库的能力外,还具有控制数据库区块链账户、数据所有权和数据库智能合约的能力。

In addition to the ability to write and read on-chain databases, IceGiant also has the ability to control database blockchain accounts, data ownership, and database smart contracts.

P21. Data distributed and available

IceGiant的链上数据库RPC广播区块链消息并执行数据库的读写操作,包括UpdateDb、Read、Check和CreateDB等功能。IceGiant的链上核心API在客户端驱动时操作链下数据库。客户端通过调用UpdateDb API发送NoSQL指令给IceGiant,后者解析通信协议并将指令传递至链下的IceFireDB数据库引擎。执行结果将返回给客户端。成功的响应表示链上区块事务和链下数据库都成功执行。IceGiant的去中心化节点同步数据指令,实现数据的去中心化存储和基于区块链的数据主权能力。数据写入交易持续存储在IceGiant的主链上,通过驱动链上API可以重新变更NoSQL或SQL的状态。总而言之,IceGiant的数据库网络确保了数据的去中心化和可用性。
IceGiant's on-chain database RPC broadcasts blockchain messages and performs database read and write operations, including functions such as UpdateDb, Read, Check, and CreateDB. IceGiant's on-chain core API operates off-chain databases while client-driven. The client sends NoSQL commands to IceGiant by calling the UpdateDb API, which parses the communication protocol and passes the commands to the IceFireDB database engine off-chain. The execution result will be returned to the client. A successful response indicates that both the on-chain block transaction and the off-chain database were executed successfully. IceGiant's decentralized nodes synchronize data instructions to realize decentralized data storage and blockchain-based data sovereignty capabilities. Data writing transactions are continuously stored on the main chain of IceGiant, and the status of NoSQL or SQL can be changed again through the API on the drive chain. All in all, IceGiant's database network ensures data decentralization and availability.

P23.Data Accessibility and Atomicity

区块链数据库更新操作只有成功或失败两种结果。 IceGiant的ABCI区块链数据库逻辑负责链上和链下状态更新。 链下数据库执行成功后,区块交易会继续在链上广播,并返回成功; 否则将返回数据更新错误,并且区块链交易将停止广播。

The blockchain database update operation has only two results: success or failure. IceGiant's blockchain database logic is responsible for on-chain and off-chain state updates. After the off-chain database is successfully executed, the block transaction will continue to be broadcast on the chain and return success; otherwise, a data update error will be returned, and the block chain transaction will stop broadcasting.

On-chain IceGiant statusOff-chain IceFireDB statusAffected IceGiant state?
SuccessSuccess
SuccessFailure
FailureNot executed

P24.Data Sovereignty and Blockchain Efficiency

IceGiant区块链是一个多账户系统,为不同类型的数据库存储提供了数据所属权机制。在NoSQL KV类型数据库中,IceGiant通过将键与钱包地址融合来隔离数据区域。在SQL关系型数据库中,IceGiant通过链上管理用户创建的表来管理数据所属权。无论数据库类型如何,数据所属权都与最小的数据集合绑定。创建数据库的账户具有对其所绑定数据的访问控制权。

The IceGiant blockchain is a multi-account system that provides data ownership mechanisms for different types of database storage. In NoSQL KV type databases, IceGiant isolates data regions by fusing keys with wallet addresses. In a SQL relational database, IceGiant manages data ownership by managing user-created tables on the chain. Regardless of database type, data ownership is tied to a minimal collection of data. The account that creates the database has access control rights to the data it is bound to.

IceGiant是一个去中心化数据库存储和数据所属权协议,旨在增强区块链的存储和数据表达能力。通过POS区块链及IceFireDB进行数据存储,避免了昂贵的存储成本,并具有高效的数据库读写性能。与其他基于事件或日志的数据库方案相比,IceGiant是区块链原生的web3数据库解决方案,支持跨链数据读写和聚合数据,实现真正的多链互操作性。

IceGiant is a decentralized database storage and data ownership protocol designed to enhance the storage and data expression capabilities of the blockchain. Data storage through POS blockchain and IceFireDB avoids expensive storage costs and has efficient database read and write performance. Compared with other event or log-based database solutions, IceGiant is a blockchain-native web3 database solution that supports cross-chain data reading and writing and data aggregation to achieve true multi-chain interoperability.

P25. IceFireLabs

在讲解了很多IceFireDB及IceGiant内容之后,我介绍一下IceFireLabs,目前我们的项目包含了今天讲解的IceFireDB及IceGiant,也包含今天没有讲解的FlowShield私有网络数据检索项目,我们在围绕web3.0的基础设施领域进行建设,也在积极和web3生态的一些基金会合作,也欢迎大家访问icefirelabs.xyz进行了解更多。

After explaining a lot of IceFireDB and IceGiant content, let me introduce IceFireLabs. At present, our projects include IceFireDB and IceGiant explained today, as well as the FlowShield private network data retrieval project that was not explained today. We are focusing on the infrastructure of web3.0 It is also actively cooperating with some foundations in the web3 ecology. Welcome to visit icefirelabs.xyz to learn more.

Currently supports RESP and SQL protocols, which are suitable for most web2 applications and widely supported by most computer languages.