> For the complete documentation index, see [llms.txt](https://docs.decentraland.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.decentraland.org/contributor/contributor-zh/jia-gou/architecture.md).

# 概览

Decentraland 是一个去中心化虚拟世界平台，构建于一种混合架构之上，结合了区块链所有权、去中心化内容分发和集中式服务，以提升用户体验。

## 架构原则

### 在关键之处去中心化

* **所有权** - 土地、穿戴物和名称都是以太坊上的 NFT
* **治理** - DAO 控制关键智能合约和资金库
* **内容** - 分布在 Catalyst 节点之间
* **身份** - 基于钱包的身份验证（无密码）

### 为性能而集中化

* **实时服务** - WebSocket 通信、语音聊天
* **发现** - 搜索、活动、精选内容
* **社交功能** - 好友、社区、通知
* **优化** - 资源处理、图像生成

## 系统层

### 客户端

玩家通过各种客户端进行交互：

* **Unity Explorer** - 主要桌面客户端（Windows、Mac、Linux）
* **Web Explorer** - 基于浏览器的客户端
* **CLI** - 用于场景创建和部署的开发者工具
* **社区客户端** （移动端、VR 等）- 使用不同渲染技术为参考客户端提供的替代实现。

所有客户端都通过加密钱包进行身份验证，并遵循相同的协议。

### 发现（Realm 提供商）

向客户端提供领域描述的单一入口点：

* 可用的 Catalyst 节点（位置、容量、健康状态）
* 后端服务端点

支持基于地理位置和负载的智能服务器选择。

### 去中心化内容（Catalyst 网络）

无需许可的 Catalyst 节点网络，用于存储和提供：

* 场景定义和资源
* 头像资料和穿戴物

每个节点都会独立验证并存储内容。节点会同步部署，但以自治方式运行。见 [Catalyst 网络](/contributor/contributor-zh/jia-gou/catalyst.md) 详见。

### 集中式功能服务器

后端微服务提供增强功能：

* **服务发现** - 领域选择和健康监控
* **通信** - WebSocket 集群、语音/视频访问控制
* **内容功能** - 世界、活动、地点、地图集数据
* **社交功能** - 好友、社区、通知
* **平台功能** - 成就、奖励、虚拟积分
* **资源处理** - 优化、缩略图、翻译

参见 [后端服务](/contributor/contributor-zh/jia-gou/services.md) 用于完整的服务文档。

### 基础设施

支持系统和第三方服务：

* **消息代理** - 用于服务间通信的 NATS
* **媒体服务器** - 用于语音和视频的 LiveKit
* **区块链索引器** - 用于 NFT 数据的快速查询
* **电子邮件服务** - 用于通知的 SendGrid

参见 [基础设施](/contributor/contributor-zh/jia-gou/infrastructure.md) 详见。

### 区块链

以太坊和 Polygon 上的智能合约管理：

* **所有权** - LAND、穿戴物、名称、地产
* **市场** - 交易和版税
* **DAO** - 治理和资金库
* **货币** - MANA 代币

## 安全模型

### 身份与认证

* **钱包签名** - 无密码，通过以太坊签名进行身份验证
* **认证服务器** - 在签名验证后签发 JWT 令牌
* **签名获取** - API 使用钱包签名对请求进行身份验证

### 内容验证

* **签名验证** - 所有部署都由钱包签名
* **指针所有权** - 只有 LAND 所有者才能向坐标部署内容
* **大小限制** - 内容大小受地块数量限制

### 访问控制

* **限时令牌** - JWT 和 LiveKit 令牌会过期
* **速率限制** - 按 IP/用户设置 API 速率限制
* **DDoS 防护** - 分布式 Catalyst 网络

## 可扩展性方法

### 水平扩展

* **Catalyst 节点** - 随着内容增长添加节点
* **后端服务** - 无状态微服务可独立扩展
* **岛屿** - 通信按基于邻近性的组进行拆分

### 优化

* **资源包** - 平台优化后的资源（Unity 包）
* **CDN** - 静态资源通过 CDN 提供
* **缓存** - 在所有层进行积极缓存
* **索引器** - 区块链数据缓存在高速数据库中

## 下一步

深入了解特定架构领域：

* [**后端服务**](/contributor/contributor-zh/jia-gou/services.md) - 详细的服务规范和集成
* [**Catalyst 网络**](/contributor/contributor-zh/jia-gou/catalyst.md) - 内容分发和部署
* [**基础设施**](/contributor/contributor-zh/jia-gou/infrastructure.md) - 支持系统和第三方服务

## 其他资源

* [API 参考](https://github.com/decentraland/docs/blob/main/apis/README.md) - 完整的 API 文档
* [贡献者指南](/contributor/contributor-zh/gong-xian-zhe-zhi-nan/contributor-guides.md) - 开发标准
* [GitHub 组织](https://github.com/decentraland) - 源代码仓库


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.decentraland.org/contributor/contributor-zh/jia-gou/architecture.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
