forked from cosmos/cosmos-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge PR cosmos#4430: update "intro docs" cn translation to 05/27
- Loading branch information
1 parent
8b1d75c
commit 3968f63
Showing
6 changed files
with
129 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Cosmos SDK 文档 | ||
|
||
## 开始 | ||
|
||
- **[SDK 介绍](./intro/README.md)**:从“高层”了解Cosmos SDK. | ||
- **[SDK 开发教程](https://github.com/cosmos/sdk-application-tutorial)**: 一个学习 SDK 的教程。它展示了如何从头开始基于 sdk 构建区块链, 并在此过程中解释了 SDK 的基本原理。 | ||
|
||
|
||
## 开发资源 | ||
|
||
- [规范](./spec/README.md): Cosmos SDK 的模块及其他规范。 | ||
- [SDK API 参考](https://godoc.org/github.com/cosmos/cosmos-sdk): Cosmos SDK Godocs 文档 。 | ||
- [REST API 规范](https://cosmos.network/rpc/): 通过 REST 与 `gaia` 全节点交互的 API 列表。 | ||
|
||
## 创建新的 SDK 项目 | ||
|
||
若要创建新项目, 以下两个方法任选其一: | ||
|
||
- 克隆这个 [教程](https://github.com/cosmos/sdk-application-tutorial/),如果不需要, 请不要忘记从各种文件中删除 `nameservice` 模块。 | ||
- 使用社区工具, 如 [chainkit](https://github.com/blocklayerhq/chainkit). | ||
|
||
## Cosmos Hub | ||
|
||
Cosmos Hub (名为 `gaia`) 文档已经迁移到[这里](https://github.com/cosmos/gaia/tree/master/docs). | ||
|
||
## 开发语言 | ||
|
||
Cosmos-SDK 目前是用 [Golang](https://golang.org/)编写的, 尽管该框架同样可以在其他语言中实现。请联系我们获取有关资助其他语言实现的信息。 | ||
|
||
## 贡献 | ||
|
||
参考 [文档说明](https://github.com/cosmos/cosmos-sdk/blob/master/docs/DOCS_README.md) 了解构建细节及更新时注意事项。 | ||
|
||
## 版本 | ||
|
||
这份文档通过以下提交构建: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,31 @@ | ||
## SDK介绍 | ||
# SDK介绍 | ||
|
||
[Cosmos-SDK](https://github.com/cosmos/cosmos-sdk) 是一个架构,用于构建多资产股权证明(PoS)的区块链,比如Cosmos Hub,以及权益证明(PoA)的区块链。 | ||
## 什么是Cosmos SDK? | ||
|
||
Cosmos SDK的目标是允许开发者从头开始轻松创建原生就能同其他区块链相互操作的自定义区块链。我们设想SDK是类似于npm这样的框架,以在[Tendermint](https://github.com/tendermint/tendermint)之上构建安全的区块链应用程序。 | ||
[Cosmos-SDK](https://github.com/cosmos/cosmos-sdk) 是一个架构,用于构建多资产股权证明(PoS)的区块链,比如Cosmos Hub,以及权益证明(PoA)的区块链。使用Cosmos SDK构建的区块链通常称为**特定应用区块链**。 | ||
|
||
它基于两个主要原则: | ||
+ **可组合性** :任何人都可以为Cosmos-SDK创建模块,并且集成已经构建的模块就像将它们导入你的区块链应用程序那样简单。 | ||
+ **能力** :SDK受基于功能的安全性的启发,及多年来解决区块链状态机的经验。大多数开发人员在构建自己的模块时需要访问其他第三方模块。鉴于Cosmos-SDK是一个开放框架,一些模块可能是恶意的,这意味着需要安全原则来推理模块间的交互。这些原则基于对象能力。实际上,这意味着不是让每个模块保留其他模块的访问控制列表,而是每个模块都实现称为keeper的特殊对象,这些对象可以传递给其他模块以授予预先定义的一组功能。例如,如果模块A的keeper的实例被传递给模块B,则后者将能够调用一些受限制的模块A的函数。每个keeper的功能由模块的开发人员定义,开发人员需要根据传递到每个第三方模块的功能来理解和审计第三方模块外部代码的安全性。要深入了解请跳转到[本节](./ocap.md)。 | ||
Cosmos SDK的目标是允许开发者从头开始轻松创建原生就能同其他区块链相互操作的自定义区块链。我们设想SDK类似于Ruby-on-Rails框架之上构建应用一样,可以很方便在[Tendermint](https://github.com/tendermint/tendermint)之上构建安全的区块链应用。 基于SDK的区块链通过可组合的模块构建出来的,大部分模块是开源的,并且可供任何开发人员使用。 任何人都可以为Cosmos-SDK 创建一个模块,集成已经构建的模块就像将它们导入到区块链应用程序一样简单。 更重要的是,Cosmos SDK是一个基于**能力**(capabilities)的系统,开发人员可以更好地了解模块之间交互的安全性。 要深入了解能力,请跳到[OCAP](./ocap.md)。 | ||
|
||
### 接着,学习[SDK应用程序架构](./sdk-app-architecture.md) | ||
## 什么是特定应用区块链? | ||
|
||
|
||
今天区块链的一个发展模式是像以太坊这样的虚拟机区块链,开发通常围绕着在现有区块链之上通过智能合约构建一个去中心化的应用程序。 虽然智能合约对于像单用途应用程序(如ICO)这样的一些场景非常有用,但对于构建复杂的去中心化平台往往是不够的。 更一般地说,智能合约在灵活性、主权和性能方面受到限制。 | ||
|
||
特定应用区块链提供了与虚拟机区块链截然不同的开发模式。 特定应用区块链是一个定制的区块链来服务单个应用程序:开发人员可以自由地做出应用程序运行最佳所需的设计决策。 它们还可以提供更好的主权、安全和性能。 | ||
|
||
要了解有关特定应用区块链的更多信息,可参考[这里](./why-app-specific.md)。 | ||
|
||
## 为什么是 Cosmos SDK? | ||
|
||
Cosmos SDK 是目前用于构建自定义的特定应用区块链的最先进的框架。 以下是一些你可能需要考虑使用 Cosmos SDK 构建去中心化应用的原因: | ||
|
||
* SDK中默认共识引擎是 [Tendermint Core](https://github.com/tendermint/tendermint) 。 Tendermint 是已存在的最成熟(也是唯一的)的BFT共识引擎。 它被广泛应用于行业,被认为是建立股权证明系统(POS)的黄金标准共识引擎。 | ||
* SDK是开源的,旨在使其易于从可组合模块中构建区块链。 随着开源SDK模块生态系统的发展,使用它构建复杂的去中心化平台将变得越来越容易。 | ||
* SDK 受基于能力的安全性启发,及多年来解决区块链状态机的经验。 这使得 Cosmos SDK 成为构建区块链的非常安全的环境。 | ||
* 最重要的是,Cosmos SDK已经被许多特定应用区块链产品所使用。 如:[Cosmos Hub](https://hub.cosmos.network), [Iris](https://irisnet.org), [Binance Chain](https://docs.binance.org/), [Terra](https://terra.money/) or [Lino](https://lino.network/) ,除此之外还有很多建立在Cosmos SDK的项目。 你可以在这里查看[生态系统](https://cosmos.network/ecosystem)。 | ||
|
||
|
||
## 开始使用 Cosmos SDK | ||
|
||
* 了解[SDK 应用体系架构](./sdk-app-architecture.md)的详细信息 | ||
* 了解如何从头构建特定应用区块链,参考[SDK教程](/docs/tutorial) 。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.