Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add 3.10.0 doc #1823

Merged
merged 2 commits into from
Aug 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions 2.x/docs/compatibility.md

Large diffs are not rendered by default.

136 changes: 136 additions & 0 deletions 3.x/zh_CN/docs/introduction/change_log/3_10_0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
# v3.10.0

## 新增

-
新增feature开关feature_evm_cancun,用于控制EVM升级至CANCUN版本。相关PR:[#4332](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4332)
- EVM支持至CANCUN版本,支持TLOAD, TSTORE, MCOPY, BLOBHASH and
BLOBBASEFEE等最新操作码,支持soldity为0.8.26版本合约部署。相关PR:[#4332](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4332)
- 一键搭链脚本增加开启日志级别为debug功能。相关PR:[#4411](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4511)

## 修复

*
解决baseline模式下合约不存在时返回码与串行模式不同的问题。相关PR:[#4512](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4512)
* 解决baseline模式下合约revert时可能会内存泄露的问题。相关PR:[#4554](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4554)
*
限制baseline模式下缓存合约executive的数量,减少内存占用。相关PR:[#4559](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4559)
* 修复Web3 JSON RPC部分接口不填入Block
Tag导致节点退出的问题。PR:[#4547](https://github.com/FISCO-BCOS/FISCO-BCOS/pull/4559)

## 兼容性说明

### 兼容版本

需要升级的链的“数据兼容版本号([compatibility_version](#id5))”为如下版本时:

* 3.4.x、3.5.x,3.6.x、3.7.x、3.8.x:数据完全兼容当前版本,直接替换二进制即可完成升级
*
3.3.x、3.2.x、3.1.x、3.0.x:支持通过替换二进制进行灰度升级,若需使用当前版本的新特性,需升级数据兼容版本号,操作见[文档](#id5)
* 3.0-rc x:数据不兼容,无法升级,可考虑逐步将业务迁移至3.x正式版
* 2.x:数据不兼容,2.x版本仍持续维护,可考虑升级为2.x的最新版本

### 实验功能

效果:通过feature开关控制实验功能的开启

操作:升级节点可执行程序后,通过控制台命令`setSystemConfigByKey <feature名> 1` 开启对应实验功能,具体操作见文档升级方法部分

注意事项:

* feature操作不可逆,打开后不可关闭
* 需确认所有可执行程序版本相同后,再进行feature开启操作

| | Feature 名 | 默认状态 | 说明 |
|--------------|----------------------------|------|--------------------------------------------|
| 资产管理 | feature_balance | 关:0 | 默认关闭 |
| 资产操作预编译合约 | feature_balance_precompile | 关:0 | 默认关闭 |
| 计费模式 | feature_policy1 | 关:0 | 默认关闭 |
| 块内分片 | feature_sharding | 关:0 | 默认关闭,仅在从3.3、3.4升级至当前版本时,feature_sharding打开 |
| 同态加密 | feature_paillier | 关:0 | 默认关闭 |
| rpbft共识 | feature_rpbft | 关:0 | 默认关闭 |
| EVM升级至CANCUN | feature_evm_cancun | 关:0 | 默认关闭 |
| bug修复 | bugfix_\<bug_name\> | 开:1 | 从低版本升级默认关闭 |

**组件兼容性**

| | 推荐版本 | 最低版本 | 说明 |
|------------|-------------|---------------------|-------------------|
| WeBASE | 3.0.2 | 3.0.2 | |
| WeIdentity | v3.0.0-rc.1 | v3.0.0-rc.1 | |
| Console | 3.8.0 | 3.0.0 | |
| Java SDK | 3.8.0 | 3.0.0 | |
| CPP SDK | 3.8.0 | 3.0.0 | |
| Solidity | 0.8.26 | 最低 0.4.25,最高 0.8.26 | 需根据合约版本下载编译器(控制台) |
| WBC-Liquid | 1.0.0-rc3 | 1.0.0-rc3 | |

#### 升级方法

该操作仅支持将3.x版本升级为本版本,不支持3.0-rc或2.x的升级。

##### 查询数据兼容版本号(compatibility_version)

用[控制台](https://fisco-bcos-doc.readthedocs.io/zh_CN/latest/docs/operation_and_maintenance/console/console_commands.html#getsystemconfigbykey)
进行查询,如当前返回的版本为3.9.0

```
[group0]: /apps> getSystemConfigByKey compatibility_version
3.9.0
```

##### 替换节点二进制

需将**所有节点**
的二进制逐步替换为当前版本。为了不影响业务,替换过程能够以灰度方式进行,逐个替换并重启节点。替换过程中,当前的链仍然会以旧的数据兼容版本号的逻辑继续执行。当所有节点二进制替换完成并重启后,需用控制台修改数据兼容版本号为当前版本。

##### 设置数据兼容版本号(compatibility_version)

用[控制台](https://fisco-bcos-doc.readthedocs.io/zh_CN/latest/docs/operation_and_maintenance/console/console_commands.html#setsystemconfigbykey)
设置数据兼容版本号,如当前版本为3.9.0。

```
[group0]: /apps> setSystemConfigByKey compatibility_version 3.9.0
{
"code":0,
"msg":"success"
}

注:若开启权限治理功能,需要使用 setSysConfigProposal 命令
```

设置成功,再次查询,得到当前版本已升级为3.10.0

```
[group0]: /apps> getSystemConfigByKey compatibility_version
3.10.0
```

当前链已经完成升级,至此,**链开始以新的逻辑继续运行**,并支持了新的特性。

#### EVM升级至CANCUN使用说明

首先通过控制台命令`setSystemConfigByKey feature_evm_cancun 1`开启EVM升级至CANCUN功能,然后部署0.8.26版本的合约。

注意:在部署0.8.26版本合约时,需要在depoly 后面指定sol-version 为0.8.26,如下所示:

```

[group0]: /apps> deploy StorageSlot.sol --sol-version 0.8.26
transaction hash: 0x8f3564047e3dd2913ed30f193e10c2b8af2b24896ce10b8add8eb47b888d7505
contract address: 0x29f1926cab679bc8bdd0757fb92adf020c8bd398
currentAccount: 0x0296737557c85bde21b4cf766c3f85e2e4c14d66

// 否则使用默认0.8.11版本编译则会报错
[group0]: /apps> deploy StorageSlot.sol
Warning: SPDX license identifier not provided in source file. Before publishing, consider adding a comment containing "SPDX-License-Identifier: <SPDX-License>" to each source file. Use "SPDX-License-Identifier: UNLICENSED" for non-open-source code. Please see https://spdx.org for more information.
--> StorageSlot.sol

Error: Function "tload" not found.
--> StorageSlot.sol:127:22:
|
127 | value := tload(slot)
| ^^^^^

Error: Variable count for assignment to "value" does not match number of values (1 vs. 0)

```
8 changes: 4 additions & 4 deletions 3.x/zh_CN/docs/introduction/change_log/3_9_0.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# v3.8.0
# v3.9.0

## 新增

Expand Down Expand Up @@ -84,7 +84,7 @@
设置数据兼容版本号,如当前版本为3.7.0。

```
[group0]: /apps> setSystemConfigByKey compatibility_version 3.8.0
[group0]: /apps> setSystemConfigByKey compatibility_version 3.9.0
{
"code":0,
"msg":"success"
Expand All @@ -93,11 +93,11 @@
注:若开启权限治理功能,需要使用 setSysConfigProposal 命令
```

设置成功,再次查询,得到当前版本已升级为3.8.0
设置成功,再次查询,得到当前版本已升级为3.9.0

```
[group0]: /apps> getSystemConfigByKey compatibility_version
3.8.0
3.9.0
```

当前链已经完成升级,至此,**链开始以新的逻辑继续运行**,并支持了新的特性。
19 changes: 10 additions & 9 deletions 3.x/zh_CN/docs/introduction/change_log/feature_bugfix_list.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@

## 1. feature功能开关

| | Feature 名 | 默认状态 | 说明 |
|--------------------|----------------------------|----------|----------------------------------------------------------------|
| 资产管理 | feature_balance | 关:0 | 默认关闭 |
| 资产操作预编译合约 | feature_balance_precompile | 关:0 | 默认关闭 |
| 计费模式 | feature_policy1 | 关:0 | 默认关闭 |
| 块内分片 | feature_sharding | 关:0 | 默认关闭,仅在从3.3、3.4升级至当前版本时,feature_sharding打开 |
| 同态加密 | feature_paillier | 关:0 | 默认关闭 |
| rpbft共识 | feature_rpbft | 关:0 | 默认关闭 |
| dmc切换至串行 | feature_dmc2serial | 关:0 | 默认关闭 |
| | Feature 名 | 默认状态 | 说明 |
|--------------|----------------------------|------|--------------------------------------------|
| 资产管理 | feature_balance | 关:0 | 默认关闭 |
| 资产操作预编译合约 | feature_balance_precompile | 关:0 | 默认关闭 |
| 计费模式 | feature_policy1 | 关:0 | 默认关闭 |
| 块内分片 | feature_sharding | 关:0 | 默认关闭,仅在从3.3、3.4升级至当前版本时,feature_sharding打开 |
| 同态加密 | feature_paillier | 关:0 | 默认关闭 |
| rpbft共识 | feature_rpbft | 关:0 | 默认关闭 |
| dmc切换至串行 | feature_dmc2serial | 关:0 | 默认关闭 |
| EVM升级至CANCUN | feature_evm_cancun | 关:0 | 默认关闭 |

## 2. bugfix列表

Expand Down
20 changes: 20 additions & 0 deletions 3.x/zh_CN/docs/introduction/change_log/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,26 @@ FISCO BCOS 设计 Feature控制特性功能开启关闭,用户可以根据自
:maxdepth: 0

upgrade.md
v3.10.x
------------------

.. admonition:: FISCO BCOS 3.x Releases

- `FISCO BCOS v3.10.0 <./3_10_0.html>`_ [`release <https://github.com/FISCO-BCOS/FISCO-BCOS/releases/tag/v3.10.0>`_]

.. admonition:: 查看节点和数据版本

- 查看Air版本FISCO BCOS节点二进制版本:``./fisco-bcos --version``
- 查看Pro版本FISCO BCOS节点二进制版本:``./BcosNodeService --version``, ``./BcosRpcService --version``, ``./BcosGatewayService --version``
- 查看Max版本FISCO BCOS节点二进制版本:``./BcosMaxNodeService --version``, ``./BcosRpcService --version``, ``./BcosGatewayService --version``, ``./BcosExecutorService --version``
- 查看轻节点二进制版本:``../fisco-bcos-lightnode --version``
- 查看轻节点相关文档,请参考 [`轻节点搭建工具 <https://fisco-bcos-doc.readthedocs.io/zh_CN/latest/docs/tutorial/lightnode.html>`_]

.. toctree::
:hidden:
:maxdepth: 0

3_10_0.md

v3.9.x
------------------
Expand Down
6 changes: 3 additions & 3 deletions 3.x/zh_CN/docs/quick_start/air_installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,18 +49,18 @@ sudo yum install -y curl openssl openssl-devel wget

```eval_rst
.. note::
如果因为网络问题导致长时间无法下载build_chain.sh脚本,请尝试 curl -#LO https://osp-1257653870.cos.ap-guangzhou.myqcloud.com/FISCO-BCOS/FISCO-BCOS/releases/v3.9.0/build_chain.sh && chmod u+x build_chain.sh
如果因为网络问题导致长时间无法下载build_chain.sh脚本,请尝试 curl -#LO https://osp-1257653870.cos.ap-guangzhou.myqcloud.com/FISCO-BCOS/FISCO-BCOS/releases/v3.10.0/build_chain.sh && chmod u+x build_chain.sh
```

```shell
# 创建操作目录
cd ~ && mkdir -p fisco && cd fisco

# 下载建链脚本
curl -#LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/v3.9.0/build_chain.sh && chmod u+x build_chain.sh
curl -#LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/v3.10.0/build_chain.sh && chmod u+x build_chain.sh

# Note: 若访问git网速太慢,可尝试如下命令下载建链脚本:
curl -#LO https://osp-1257653870.cos.ap-guangzhou.myqcloud.com/FISCO-BCOS/FISCO-BCOS/releases/v3.9.0/build_chain.sh && chmod u+x build_chain.sh
curl -#LO https://osp-1257653870.cos.ap-guangzhou.myqcloud.com/FISCO-BCOS/FISCO-BCOS/releases/v3.10.0/build_chain.sh && chmod u+x build_chain.sh
```

### 第三步. 搭建4节点非国密联盟链
Expand Down
2 changes: 1 addition & 1 deletion 3.x/zh_CN/docs/quick_start/solidity_application.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ function transfer(string memory from_account, string memory to_account, uint256
mkdir -p ~/fisco

# 下载控制台
cd ~/fisco && curl -#LO https://github.com/FISCO-BCOS/console/releases/download/v3.6.0/download_console.sh && bash download_console.sh
cd ~/fisco && curl -#LO https://github.com/FISCO-BCOS/console/releases/download/v3.10.0/download_console.sh && bash download_console.sh

# 切换到fisco/console/目录
cd ~/fisco/console/
Expand Down
2 changes: 1 addition & 1 deletion 3.x/zh_CN/docs/quick_start/wbc_liquid_application.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ pub fn transfer(&mut self, from: String, to: String, value: u128) -> i16
mkdir -p ~/fisco

# 下载控制台
cd ~/fisco && curl -#LO https://github.com/FISCO-BCOS/console/releases/download/v3.6.0/download_console.sh && bash download_console.sh
cd ~/fisco && curl -#LO https://github.com/FISCO-BCOS/console/releases/download/v3.10.0/download_console.sh && bash download_console.sh

# 切换到fisco/console/目录
cd ~/fisco/console/
Expand Down
Loading
Loading