This is an automated email from the ASF dual-hosted git repository.
panjuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new da6be54 remove worker id configuration for snowflake algorithm
(#14861)
da6be54 is described below
commit da6be5421cce3c5a7ad0e4cdea94718357b00aa3
Author: Haoran Meng <[email protected]>
AuthorDate: Tue Jan 18 17:44:14 2022 +0800
remove worker id configuration for snowflake algorithm (#14861)
---
.../api-change-history/shardingsphere-jdbc/java-api.cn.md | 1 -
.../api-change-history/shardingsphere-jdbc/java-api.en.md | 1 -
.../shardingsphere-jdbc/spring-boot-starter.cn.md | 4 ++--
.../shardingsphere-jdbc/spring-boot-starter.en.md | 5 ++---
.../shardingsphere-jdbc/spring-namespace-configuration.cn.md | 1 -
.../shardingsphere-jdbc/spring-namespace-configuration.en.md | 1 -
.../shardingsphere-jdbc/yaml-configuration.cn.md | 6 +++---
.../shardingsphere-jdbc/yaml-configuration.en.md | 4 ++--
.../content/reference/test/module-test/rewrite-test.cn.md | 2 --
.../content/reference/test/module-test/rewrite-test.en.md | 2 --
.../reference/test/performance-test/benchmarksql-test.cn.md | 2 --
.../reference/test/performance-test/performance-test.cn.md | 6 ------
.../reference/test/performance-test/performance-test.en.md | 6 ------
.../reference/test/performance-test/sysbench-test.en.md | 4 ----
.../shardingsphere-jdbc/builtin-algorithm/keygen.cn.md | 1 -
.../shardingsphere-jdbc/builtin-algorithm/keygen.en.md | 1 -
.../user-manual/shardingsphere-jdbc/java-api/rules/mix.cn.md | 1 -
.../user-manual/shardingsphere-jdbc/java-api/rules/mix.en.md | 1 -
.../shardingsphere-jdbc/spring-boot-starter/rules/mix.cn.md | 1 -
.../shardingsphere-jdbc/spring-boot-starter/rules/mix.en.md | 1 -
.../distsql/syntax/rdl/rule-definition/sharding.cn.md | 8 ++++----
.../distsql/syntax/rdl/rule-definition/sharding.en.md | 8 ++++----
.../distsql/syntax/rql/rule-query/sharding.cn.md | 10 +++++-----
.../distsql/syntax/rql/rule-query/sharding.en.md | 10 +++++-----
.../shardingsphere-proxy/distsql/usage/sharding-rule.cn.md | 2 +-
.../shardingsphere-proxy/distsql/usage/sharding-rule.en.md | 2 +-
.../content/user-manual/shardingsphere-scaling/usage.cn.md | 6 +++---
.../content/user-manual/shardingsphere-scaling/usage.en.md | 6 +++---
28 files changed, 35 insertions(+), 68 deletions(-)
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.cn.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.cn.md
index 34600b1..4e6cbe1 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.cn.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.cn.md
@@ -343,7 +343,6 @@ SNOWFLAKE
| *名称* | *数据类型* | *说明*
|
| :--------------------------------------------- | :---------- |
:------------------------------------------------------- |
-| worker.id (?) | long | 工作机器唯一 id,默认为 0
|
| max.tolerate.time.difference.milliseconds (?) | long |
最大容忍时钟回退时间,单位:毫秒。默认为 10 毫秒 |
| max.vibration.offset (?) | int | 最大抖动上限值,范围 [0,
4096),默认为 1。<br/> 注:若使用此算法生成值作分片值,建议配置此属性。<br/> 此算法在不同毫秒内所生成的 key 取模 2^n (2^n
一般为分库或分表数) 之后结果总为 0 或 1。<br/> 为防止上述分片问题,建议将此属性值配置为 (2^n)-1 |
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.en.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.en.md
index 72230a3..67204da 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.en.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/java-api.en.md
@@ -343,7 +343,6 @@ SNOWFLAKE
| *Name* | *Data Type* | *Explanation*
|
| :--------------------------------- | :---------- |
:----------------------------------------------------------- |
-| worker.id (?) | long | The unique id for
working machine, the default value is `0` |
| max.tolerate.time.difference.milliseconds (?) | long | The max tolerate time
for different server’s time difference in milliseconds, the default value is
`10` |
| max.vibration.offset (?) | int | The max upper limit value of vibrate
number, range `[0, 4096)`, the default value is `1`. Notice: To use the
generated value of this algorithm as sharding value, it is recommended to
configure this property. The algorithm generates key mod `2^n` (`2^n` is
usually the sharding amount of tables or databases) in different milliseconds
and the result is always `0` or `1`. To prevent the above sharding problem, it
is recommended to configure this property, i [...]
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.cn.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.cn.md
index c6ecb9b..e393d47 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.cn.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.cn.md
@@ -162,7 +162,7 @@
spring.shardingsphere.sharding.tables.<logic-table-name>.table-strategy.xxx= #
spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.column=
# 自增列名称,缺省表示不使用自增主键生成器
spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.type= #
自增列值生成器类型,缺省表示使用默认自增列值生成器。可使用用户自定义的列值生成器或选择内置类型:SNOWFLAKE/UUID
-spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.props.<property-name>=
# 属性配置, 注意:使用 SNOWFLAKE 算法,需要配置 worker.id 与
max.tolerate.time.difference.milliseconds 属性。若使用此算法生成值作分片值,建议配置
max.vibration.offset 属性
+spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.props.<property-name>=
# 属性配置, 注意:使用 SNOWFLAKE 算法,需要配置 max.tolerate.time.difference.milliseconds
属性。若使用此算法生成值作分片值,建议配置 max.vibration.offset 属性
spring.shardingsphere.sharding.binding-tables[0]= # 绑定表规则列表
spring.shardingsphere.sharding.binding-tables[1]= # 绑定表规则列表
@@ -176,7 +176,7 @@ spring.shardingsphere.sharding.default-data-source-name= #
未配置分片规则
spring.shardingsphere.sharding.default-database-strategy.xxx= # 默认数据库分片策略,同分库策略
spring.shardingsphere.sharding.default-table-strategy.xxx= # 默认表分片策略,同分表策略
spring.shardingsphere.sharding.default-key-generator.type= # 默认自增列值生成器类型,缺省将使用
org.apache.shardingsphere.core.keygen.generator.impl.SnowflakeKeyGenerator。可使用用户自定义的列值生成器或选择内置类型:SNOWFLAKE/UUID
-spring.shardingsphere.sharding.default-key-generator.props.<property-name>= #
自增列值生成器属性配置, 比如 SNOWFLAKE 算法的 worker.id 与
max.tolerate.time.difference.milliseconds
+spring.shardingsphere.sharding.default-key-generator.props.<property-name>= #
自增列值生成器属性配置, 比如 SNOWFLAKE 算法的 max.tolerate.time.difference.milliseconds
spring.shardingsphere.sharding.master-slave-rules.<master-slave-data-source-name>.master-data-source-name=
# 详见读写分离部分
spring.shardingsphere.sharding.master-slave-rules.<master-slave-data-source-name>.slave-data-source-names[0]=
# 详见读写分离部分
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.en.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.en.md
index e7a2855..ce8a611 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.en.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-boot-starter.en.md
@@ -191,7 +191,6 @@
spring.shardingsphere.rules.sharding.sharding-algorithms.user-table-strategy-inl
# Key generate algorithm configuration
spring.shardingsphere.rules.sharding.key-generators.snowflake.type=SNOWFLAKE
-spring.shardingsphere.rules.sharding.key-generators.snowflake.props.worker-id=123
# read query configuration
# ds_0,ds_1 is the logical data source name of the readwrite-splitting
@@ -247,7 +246,7 @@
spring.shardingsphere.sharding.tables.<logic-table-name>.table-strategy.xxx= #Om
spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.column=
#Auto-increment column name; default means not using auto-increment key
generator
spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.type=
#Auto-increament key generator type; default means using default
auto-increament key generator; user defined generator or internal generator
(SNOWFLAKE, UUID) can both be selected
-spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.props.<property-name>=
#Properties, Notice: when use SNOWFLAKE, `worker.id` and
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE` need to be set. To
use the generated value of this algorithm as sharding value, it is recommended
to configure `max.vibration.offset`
+spring.shardingsphere.sharding.tables.<logic-table-name>.key-generator.props.<property-name>=
#Properties, Notice: when use SNOWFLAKE,
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE` need to be set. To
use the generated value of this algorithm as sharding value, it is recommended
to configure `max.vibration.offset`
spring.shardingsphere.sharding.binding-tables[0]= #Binding table rule list
spring.shardingsphere.sharding.binding-tables[1]= #Binding table rule list
@@ -261,7 +260,7 @@ spring.shardingsphere.sharding.default-data-source-name=
#Tables without shardin
spring.shardingsphere.sharding.default-database-strategy.xxx= #Default
database sharding strategy
spring.shardingsphere.sharding.default-table-strategy.xxx= #Default table
sharding strategy
spring.shardingsphere.sharding.default-key-generator.type= #Default
auto-increament key generator of type; it will use
org.apache.shardingsphere.core.keygen.generator.impl.SnowflakeKeyGenerator in
default; user defined generator or internal generator (SNOWFLAKE or UUID) can
both be used
-spring.shardingsphere.sharding.default-key-generator.props.<property-name>=
#Auto-increament key generator property configuration, such as worker.id and
max.tolerate.time.difference.milliseconds of SNOWFLAKE algorithm
+spring.shardingsphere.sharding.default-key-generator.props.<property-name>=
#Auto-increament key generator property configuration, such as
max.tolerate.time.difference.milliseconds of SNOWFLAKE algorithm
spring.shardingsphere.sharding.master-slave-rules.<master-slave-data-source-name>.master-data-source-name=
#Refer to readwrite-splitting part for more details
spring.shardingsphere.sharding.master-slave-rules.<master-slave-data-source-name>.slave-data-source-names[0]=
#Refer to readwrite-splitting part for more details
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.cn.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.cn.md
index 934ba19..166f5e5 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.cn.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.cn.md
@@ -375,7 +375,6 @@ weight = 3
| *名称* | *类型* | *说明*
|
| --------------------------------------------- | ------ |
------------------------------------------------------------ |
-| worker.id (?) | long | 工作机器唯一id,默认为0
|
| max.tolerate.time.difference.milliseconds (?) | long |
最大容忍时钟回退时间,单位:毫秒。默认为10毫秒 |
| max.vibration.offset (?) | int | 最大抖动上限值,范围[0,
4096),默认为1。注:若使用此算法生成值作分片值,建议配置此属性。此算法在不同毫秒内所生成的key取模2^n (2^n一般为分库或分表数)
之后结果总为0或1。为防止上述分片问题,建议将此属性值配置为(2^n)-1 |
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.en.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.en.md
index 9490265..6eab5a9 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.en.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/spring-namespace-configuration.en.md
@@ -338,7 +338,6 @@ Property configuration that can include these properties of
these key generators
SNOWFLAKE
| *Name* | *Data Type* | *Explanation* |
| ------------- | --------- | --------------------------- |
-| worker.id (?) | long | The unique id for working machine, the
default value is `0` |
| max.tolerate.time.difference.milliseconds (?) | long | The max
tolerate time for different server’s time difference in milliseconds, the
default value is `10` |
| max.vibration.offset (?) | int | The max upper limit value of vibrate
number, range `[0, 4096)`, the default value is `1`. Notice: To use the
generated value of this algorithm as sharding value, it is recommended to
configure this property. The algorithm generates key mod `2^n` (`2^n` is
usually the sharding amount of tables or databases) in different milliseconds
and the result is always `0` or `1`. To prevent the above sharding problem, it
is recommended to configure this property, i [...]
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.cn.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.cn.md
index 47ccc88..636a558 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.cn.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.cn.md
@@ -195,7 +195,7 @@ shardingRule:
keyGenerator:
column: # 自增列名称,缺省表示不使用自增主键生成器
type: # 自增列值生成器类型,缺省表示使用默认自增列值生成器。可使用用户自定义的列值生成器或选择内置类型:SNOWFLAKE/UUID
- props: # 属性配置, 注意:使用 SNOWFLAKE 算法,需要配置 worker.id 与
max.tolerate.time.difference.milliseconds 属性。若使用此算法生成值作分片值,建议配置
max.vibration.offset 属性
+ props: # 属性配置, 注意:使用 SNOWFLAKE 算法,需要配置
max.tolerate.time.difference.milliseconds 属性。若使用此算法生成值作分片值,建议配置
max.vibration.offset 属性
<property-name>: # 属性名称
bindingTables: # 绑定表规则列表
@@ -213,7 +213,7 @@ shardingRule:
defaultKeyGenerator: # 默认的主键生成算法 如果没有设置,默认为 SNOWFLAKE 算法
type: # 默认自增列值生成器类型,缺省将使用
org.apache.shardingsphere.core.keygen.generator.impl.SnowflakeKeyGenerator。可使用用户自定义的列值生成器或选择内置类型:SNOWFLAKE/UUID
props:
- <property-name>: # 自增列值生成器属性配置, 比如 SNOWFLAKE 算法的 worker.id 与
max.tolerate.time.difference.milliseconds
+ <property-name>: # 自增列值生成器属性配置, 比如 SNOWFLAKE 算法的
max.tolerate.time.difference.milliseconds
masterSlaveRules: # 读写分离规则,详见读写分离部分
<data_source_name>: # 数据源名称,需要与真实数据源匹配,可配置多个 data_source_name
@@ -393,7 +393,7 @@ shardingRule: # sharding 的配置
type: # 自增键的类型,主要用于调用内置的主键生成算法有三个可用值:SNOWFLAKE(时间戳 +worker id+ 自增
id),UUID(java.util.UUID 类生成的随机 UUID),LEAF,其中 Snowflake 算法与 UUID 算法已经实现,LEAF
目前(2018-01-14)尚未实现
className: # 非内置的其他实现了 KeyGenerator 接口的类,需要注意,如果设置这个,就不能设置 type,否则 type
的设置会覆盖 class 的设置
props:
- # 定制算法需要设置的参数,比如 SNOWFLAKE 算法的 worker.id 与
max.tolerate.time.difference.milliseconds
+ # 定制算法需要设置的参数,比如 SNOWFLAKE 算法的 max.tolerate.time.difference.milliseconds
tables: # 配置表 sharding 的主要位置
sharding_t1:
actualDataNodes: master_test_${0..1}.t_order${0..1} # sharding
表对应的数据源以及物理名称,需要用表达式处理,表示表实际上在哪些数据源存在,配置示例中,意思是总共存在 4 个分片
master_test_0.t_order0,master_test_0.t_order1,master_test_1.t_order0,master_test_1.t_order1
diff --git
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.en.md
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.en.md
index c8c3d88..9b02a86 100644
---
a/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.en.md
+++
b/docs/document/content/reference/api-change-history/shardingsphere-jdbc/yaml-configuration.en.md
@@ -195,7 +195,7 @@ shardingRule:
keyGenerator:
column: # Column name of key generator
type: # Type of key generator, use default key generator if absent,
and there are three types to choose, that is, SNOWFLAKE/UUID
- props: # Properties, Notice: when use SNOWFLAKE, `worker.id` and
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE` need to be set. To
use the generated value of this algorithm as sharding value, it is recommended
to configure `max.vibration.offset`
+ props: # Properties, Notice: when use SNOWFLAKE,
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE` need to be set. To
use the generated value of this algorithm as sharding value, it is recommended
to configure `max.vibration.offset`
bindingTables: # Binding table rule configurations
- <logic_table_name1, logic_table_name2, ...>
@@ -212,7 +212,7 @@ shardingRule:
defaultKeyGenerator:
type: # Type of default key generator, use user-defined ones or built-in
ones, e.g. SNOWFLAKE, UUID. Default key generator is
`org.apache.shardingsphere.core.keygen.generator.impl.SnowflakeKeyGenerator`
column: # Column name of default key generator
- props: # Properties of default key generator, e.g. `worker.id` and
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE`
+ props: # Properties of default key generator, e.g.
`max.tolerate.time.difference.milliseconds` for `SNOWFLAKE`
masterSlaveRules: # Read-write splitting rule configuration, more details
can reference Read-write splitting part
<data_source_name>: # Data sources configuration, need consist with data
source map, multiple `data_source_name` available
diff --git
a/docs/document/content/reference/test/module-test/rewrite-test.cn.md
b/docs/document/content/reference/test/module-test/rewrite-test.cn.md
index 373ac9b..55dcda9 100644
--- a/docs/document/content/reference/test/module-test/rewrite-test.cn.md
+++ b/docs/document/content/reference/test/module-test/rewrite-test.cn.md
@@ -60,8 +60,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
验证数据存放在 `test\resources` 路径中测试类型下对应的 xml 文件中。验证数据中, `yaml-rule` 指定了环境以及 rule
的配置文件,`input` 指定了待测试的 SQL 以及参数,`output` 指定了期待的 SQL 以及参数。
diff --git
a/docs/document/content/reference/test/module-test/rewrite-test.en.md
b/docs/document/content/reference/test/module-test/rewrite-test.en.md
index 11e43f9..bc1cb25 100644
--- a/docs/document/content/reference/test/module-test/rewrite-test.en.md
+++ b/docs/document/content/reference/test/module-test/rewrite-test.en.md
@@ -60,8 +60,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
Assert data are in the xml under test type in `test\resources`. In the xml
file, `yaml-rule` means the environment configuration file path, `input`
contains the target SQL and parameters, `output` contains the expected SQL and
parameters.
diff --git
a/docs/document/content/reference/test/performance-test/benchmarksql-test.cn.md
b/docs/document/content/reference/test/performance-test/benchmarksql-test.cn.md
index 47334cd..d38c2c9 100644
---
a/docs/document/content/reference/test/performance-test/benchmarksql-test.cn.md
+++
b/docs/document/content/reference/test/performance-test/benchmarksql-test.cn.md
@@ -153,8 +153,6 @@ rules:
none:
keyGenerators:
snowflake:
- props:
- worker-id: 123
type: SNOWFLAKE
tables:
bmsql_config:
diff --git
a/docs/document/content/reference/test/performance-test/performance-test.cn.md
b/docs/document/content/reference/test/performance-test/performance-test.cn.md
index 9419cb4..fc19d92 100644
---
a/docs/document/content/reference/test/performance-test/performance-test.cn.md
+++
b/docs/document/content/reference/test/performance-test/performance-test.cn.md
@@ -118,8 +118,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
#### 主从配置
@@ -256,8 +254,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
- !READWRITE_SPLITTING
dataSources:
pr_ds_0:
@@ -371,8 +367,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
## 测试结果验证
diff --git
a/docs/document/content/reference/test/performance-test/performance-test.en.md
b/docs/document/content/reference/test/performance-test/performance-test.en.md
index 835a87d..d48c5fe 100644
---
a/docs/document/content/reference/test/performance-test/performance-test.en.md
+++
b/docs/document/content/reference/test/performance-test/performance-test.en.md
@@ -119,8 +119,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
#### Readwrite-splitting Configuration
@@ -257,8 +255,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
- !READWRITE_SPLITTING
dataSources:
pr_ds_0:
@@ -372,8 +368,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
## Test Result Verification
diff --git
a/docs/document/content/reference/test/performance-test/sysbench-test.en.md
b/docs/document/content/reference/test/performance-test/sysbench-test.en.md
index 0502d8f..9c50694 100644
--- a/docs/document/content/reference/test/performance-test/sysbench-test.en.md
+++ b/docs/document/content/reference/test/performance-test/sysbench-test.en.md
@@ -467,8 +467,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
```
config-readwrite-splitting.yaml
@@ -664,8 +662,6 @@ rules:
keyGenerators:
snowflake:
type: SNOWFLAKE
- props:
- worker-id: 123
- !READWRITE_SPLITTING
dataSources:
ds_0:
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.cn.md
b/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.cn.md
index 76f76b4..fbde360 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.cn.md
@@ -11,7 +11,6 @@ weight = 3
| *属性名称* | *数据类型* | *说明*
|
*默认值* |
| --------------------------------------------- | -------- |
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| ------- |
-| worker-id (?) | long | 工作机器唯一标识
|
0 |
| max-vibration-offset (?) | int | 最大抖动上限值,范围[0,
4096)。注:若使用此算法生成值作分片值,建议配置此属性。此算法在不同毫秒内所生成的 key 取模 2^n (2^n一般为分库或分表数) 之后结果总为 0
或 1。为防止上述分片问题,建议将此属性值配置为 (2^n)-1 | 1 |
| max-tolerate-time-difference-milliseconds (?) | long | 最大容忍时钟回退时间,单位:毫秒
| 10 毫秒
|
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.en.md
b/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.en.md
index 0ffd010..56c8f71 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.en.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/builtin-algorithm/keygen.en.md
@@ -11,7 +11,6 @@ Attributes:
| *Name* | *DataType* | *Description*
| *Default Value* |
| --------------------------------------------- | ---------- |
---------------------------------------------------------------------------- |
--------------- |
-| worker-id (?) | long | The unique ID
for working machine | 0
|
| max-tolerate-time-difference-milliseconds (?) | long | The max
tolerate time for different server's time difference in milliseconds | 10
milliseconds |
| max-vibration-offset (?) | int | The max upper
limit value of vibrate number, range `[0, 4096)`. Notice: To use the generated
value of this algorithm as sharding value, it is recommended to configure this
property. The algorithm generates key mod `2^n` (`2^n` is usually the sharding
amount of tables or databases) in different milliseconds and the result is
always `0` or `1`. To prevent the above sharding problem, it is recommended to
configure this property, [...]
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.cn.md
b/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.cn.md
index 74a1c0e..f044783 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.cn.md
@@ -71,7 +71,6 @@
defaultDatabaseStrategyInlineProps.setProperty("algorithm-expression", "ds_${use
shardingRuleConfiguration.getShardingAlgorithms().put("default_db_strategy_inline",
new ShardingSphereAlgorithmConfiguration("INLINE",
defaultDatabaseStrategyInlineProps));
// 分布式序列算法配置
Properties snowflakeProperties = new Properties();
-snowflakeProperties.setProperty("worker-id", "123");
shardingRuleConfiguration.getKeyGenerators().put("snowflake", new
ShardingSphereAlgorithmConfiguration("SNOWFLAKE", snowflakeProperties));
/* 数据加密规则配置 */
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.en.md
b/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.en.md
index 6f05363..5318d62 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.en.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/java-api/rules/mix.en.md
@@ -67,7 +67,6 @@
shardingRuleConfiguration.getShardingAlgorithms().put("default_db_strategy_inlin
// Key generate algorithm configuration
Properties snowflakeProperties = new Properties();
-snowflakeProperties.setProperty("worker-id", "123");
shardingRuleConfiguration.getKeyGenerators().put("snowflake", new
ShardingSphereAlgorithmConfiguration("SNOWFLAKE", snowflakeProperties));
/* Data encrypt rule configuration */
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.cn.md
b/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.cn.md
index 076da5c..5e83bfc 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.cn.md
@@ -80,7 +80,6 @@
spring.shardingsphere.rules.sharding.sharding-algorithms.user-detail-table-strat
# 分布式序列算法配置
spring.shardingsphere.rules.sharding.key-generators.snowflake.type=SNOWFLAKE
-spring.shardingsphere.rules.sharding.key-generators.snowflake.props.worker-id=123
# 读写分离策略配置
# ds_0,ds_1为读写分离配置的逻辑数据源名称
diff --git
a/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.en.md
b/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.en.md
index 097eafb..c49d924 100644
---
a/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.en.md
+++
b/docs/document/content/user-manual/shardingsphere-jdbc/spring-boot-starter/rules/mix.en.md
@@ -67,7 +67,6 @@
spring.shardingsphere.rules.sharding.sharding-algorithms.user-table-strategy-inl
# Key generate algorithm configuration
spring.shardingsphere.rules.sharding.key-generators.snowflake.type=SNOWFLAKE
-spring.shardingsphere.rules.sharding.key-generators.snowflake.props.worker-id=123
# read query configuration
# ds_0,ds_1 is the logical data source name of the readwrite-splitting
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.cn.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.cn.md
index 9178878..11e41bd 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.cn.md
@@ -201,11 +201,11 @@ intValue:
```sql
CREATE SHARDING KEY GENERATOR snowflake_key_generator (
-TYPE(NAME=SNOWFLAKE, PROPERTIES("worker-id"=123))
+TYPE(NAME=SNOWFLAKE)
);
ALTER SHARDING KEY GENERATOR snowflake_key_generator (
-TYPE(NAME=SNOWFLAKE, PROPERTIES("worker-id"=456))
+TYPE(NAME=SNOWFLAKE)
);
DROP SHARDING KEY GENERATOR snowflake_key_generator;
@@ -216,13 +216,13 @@ DROP SHARDING KEY GENERATOR snowflake_key_generator;
CREATE SHARDING TABLE RULE t_order (
RESOURCES(resource_0,resource_1),
SHARDING_COLUMN=order_id,TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=4)),
-GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake))
);
ALTER SHARDING TABLE RULE t_order (
RESOURCES(resource_0,resource_1,resource_2,resource_3),
SHARDING_COLUMN=order_id,TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=16)),
-GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake))
);
DROP SHARDING TABLE RULE t_order;
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.en.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.en.md
index 5207b56..c7144a5 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.en.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rdl/rule-definition/sharding.en.md
@@ -201,11 +201,11 @@ intValue:
```sql
CREATE SHARDING KEY GENERATOR snowflake_key_generator (
-TYPE(NAME=SNOWFLAKE, PROPERTIES("worker-id"=123))
+TYPE(NAME=SNOWFLAKE)
);
ALTER SHARDING KEY GENERATOR snowflake_key_generator (
-TYPE(NAME=SNOWFLAKE, PROPERTIES("worker-id"=456))
+TYPE(NAME=SNOWFLAKE))
);
DROP SHARDING KEY GENERATOR snowflake_key_generator;
@@ -216,13 +216,13 @@ DROP SHARDING KEY GENERATOR snowflake_key_generator;
CREATE SHARDING TABLE RULE t_order (
RESOURCES(resource_0,resource_1),
SHARDING_COLUMN=order_id,TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=4)),
-GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake))
);
ALTER SHARDING TABLE RULE t_order (
RESOURCES(resource_0,resource_1,resource_2,resource_3),
SHARDING_COLUMN=order_id,TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=16)),
-GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=another_id,TYPE(NAME=snowflake))
);
DROP SHARDING TABLE RULE t_order;
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.cn.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.cn.md
index bbc90fc..ae129bb 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.cn.md
@@ -149,8 +149,8 @@ mysql> SHOW SHARDING TABLE RULES;
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
| table | actual_data_nodes | actual_data_sources |
database_strategy_type | database_sharding_column |
database_sharding_algorithm_type | database_sharding_algorithm_props |
table_strategy_type | table_sharding_column | table_sharding_algorithm_type |
table_sharding_algorithm_props | key_generate_column |
key_generator_type | key_generator_props |
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
-| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2}
| order_id | SNOWFLAKE | worker-id:123 |
-| t_order_item | ds_${0..1}.t_order_item_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_item_${order_id %
2} | order_item_id | SNOWFLAKE | worker-id:123 |
+| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2}
| order_id | SNOWFLAKE | |
+| t_order_item | ds_${0..1}.t_order_item_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_item_${order_id %
2} | order_item_id | SNOWFLAKE | |
| t2 | | ds_0,ds_1 |
| | |
| mod | id | mod
| sharding-count:10 |
| | |
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
3 rows in set (0.02 sec)
@@ -162,7 +162,7 @@ mysql> SHOW SHARDING TABLE RULE t_order;
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
| table | actual_data_nodes | actual_data_sources |
database_strategy_type | database_sharding_column |
database_sharding_algorithm_type | database_sharding_algorithm_props |
table_strategy_type | table_sharding_column | table_sharding_algorithm_type |
table_sharding_algorithm_props | key_generate_column |
key_generator_type | key_generator_props |
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
-| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2} |
order_id | SNOWFLAKE | worker-id:123 |
+| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2} |
order_id | SNOWFLAKE | |
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
1 row in set (0.01 sec)
```
@@ -196,8 +196,8 @@ mysql> SHOW SHARDING KEY GENERATORS;
+------------------------+-----------+-----------------+
| name | type | props |
+------------------------+-----------+-----------------+
-| t_order_snowflake | snowflake | {worker-id=123} |
-| t_order_item_snowflake | snowflake | {worker-id=123} |
+| t_order_snowflake | snowflake | |
+| t_order_item_snowflake | snowflake | |
| uuid_key_generator | uuid | |
+------------------------+-----------+-----------------+
3 row in set (0.01 sec)
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.en.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.en.md
index c2a47ed..798d61b 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.en.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/sharding.en.md
@@ -149,8 +149,8 @@ mysql> SHOW SHARDING TABLE RULES;
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
| table | actual_data_nodes | actual_data_sources |
database_strategy_type | database_sharding_column |
database_sharding_algorithm_type | database_sharding_algorithm_props |
table_strategy_type | table_sharding_column | table_sharding_algorithm_type |
table_sharding_algorithm_props | key_generate_column |
key_generator_type | key_generator_props |
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
-| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2}
| order_id | SNOWFLAKE | worker-id:123 |
-| t_order_item | ds_${0..1}.t_order_item_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_item_${order_id %
2} | order_item_id | SNOWFLAKE | worker-id:123 |
+| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2}
| order_id | SNOWFLAKE | |
+| t_order_item | ds_${0..1}.t_order_item_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_item_${order_id %
2} | order_item_id | SNOWFLAKE | |
| t2 | | ds_0,ds_1 |
| | |
| mod | id | mod
| sharding-count:10 |
| | |
+--------------+---------------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+---------------------------------------------------+-------------------+------------------+-------------------+
3 rows in set (0.02 sec)
@@ -162,7 +162,7 @@ mysql> SHOW SHARDING TABLE RULE t_order;
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
| table | actual_data_nodes | actual_data_sources |
database_strategy_type | database_sharding_column |
database_sharding_algorithm_type | database_sharding_algorithm_props |
table_strategy_type | table_sharding_column | table_sharding_algorithm_type |
table_sharding_algorithm_props | key_generate_column |
key_generator_type | key_generator_props |
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
-| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2} |
order_id | SNOWFLAKE | worker-id:123 |
+| t_order | ds_${0..1}.t_order_${0..1} | | INLINE
| user_id | INLINE |
algorithm-expression:ds_${user_id % 2} | INLINE | order_id
| INLINE | algorithm-expression:t_order_${order_id % 2} |
order_id | SNOWFLAKE | |
+---------+----------------------------+-------------------+----------------------+------------------------+-------------------------------+----------------------------------------+-------------------+---------------------+----------------------------+----------------------------------------------+-------------------+------------------+-------------------+
1 row in set (0.01 sec)
```
@@ -196,8 +196,8 @@ mysql> SHOW SHARDING KEY GENERATORS;
+------------------------+-----------+-----------------+
| name | type | props |
+------------------------+-----------+-----------------+
-| t_order_snowflake | snowflake | {worker-id=123} |
-| t_order_item_snowflake | snowflake | {worker-id=123} |
+| t_order_snowflake | snowflake | |
+| t_order_item_snowflake | snowflake | |
| uuid_key_generator | uuid | |
+------------------------+-----------+-----------------+
3 row in set (0.01 sec)
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.cn.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.cn.md
index 51646d2..82c2fc4 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.cn.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.cn.md
@@ -32,7 +32,7 @@ CREATE SHARDING TABLE RULE t_order(
RESOURCES(ds_0,ds_1),
SHARDING_COLUMN=order_id,
TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=4)),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
);
```
diff --git
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.en.md
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.en.md
index 115fa6e..ee4b178 100644
---
a/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.en.md
+++
b/docs/document/content/user-manual/shardingsphere-proxy/distsql/usage/sharding-rule.en.md
@@ -34,7 +34,7 @@ CREATE SHARDING TABLE RULE t_order(
RESOURCES(ds_0,ds_1),
SHARDING_COLUMN=order_id,
TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=4)),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
);
```
diff --git
a/docs/document/content/user-manual/shardingsphere-scaling/usage.cn.md
b/docs/document/content/user-manual/shardingsphere-scaling/usage.cn.md
index 906a115..c92f9ab 100644
--- a/docs/document/content/user-manual/shardingsphere-scaling/usage.cn.md
+++ b/docs/document/content/user-manual/shardingsphere-scaling/usage.cn.md
@@ -173,7 +173,7 @@ ALTER SHARDING TABLE RULE t_order (
RESOURCES(ds_2, ds_3, ds_4),
SHARDING_COLUMN=order_id,
TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=6)),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
);
```
@@ -189,12 +189,12 @@ ALTER SHARDING TABLE RULE t_order (
DATANODES("ds_${2..4}.t_order_${0..1}"),
DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=user_id,SHARDING_ALGORITHM=database_inline),
TABLE_STRATEGY(TYPE=standard,SHARDING_COLUMN=order_id,SHARDING_ALGORITHM=t_order_inline),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
), t_order_item (
DATANODES("ds_${2..4}.t_order_item_${0..1}"),
DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=user_id,SHARDING_ALGORITHM=database_inline),
TABLE_STRATEGY(TYPE=standard,SHARDING_COLUMN=order_id,SHARDING_ALGORITHM=t_order_item_inline),
-GENERATED_KEY(COLUMN=order_item_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_item_id,TYPE(NAME=snowflake))
);
```
diff --git
a/docs/document/content/user-manual/shardingsphere-scaling/usage.en.md
b/docs/document/content/user-manual/shardingsphere-scaling/usage.en.md
index 18e7175..bc2ad16 100644
--- a/docs/document/content/user-manual/shardingsphere-scaling/usage.en.md
+++ b/docs/document/content/user-manual/shardingsphere-scaling/usage.en.md
@@ -175,7 +175,7 @@ ALTER SHARDING TABLE RULE t_order (
RESOURCES(ds_2, ds_3, ds_4),
SHARDING_COLUMN=order_id,
TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=6)),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
);
```
@@ -191,12 +191,12 @@ ALTER SHARDING TABLE RULE t_order (
DATANODES("ds_${2..4}.t_order_${0..1}"),
DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=user_id,SHARDING_ALGORITHM=database_inline),
TABLE_STRATEGY(TYPE=standard,SHARDING_COLUMN=order_id,SHARDING_ALGORITHM=t_order_inline),
-GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_id,TYPE(NAME=snowflake))
), t_order_item (
DATANODES("ds_${2..4}.t_order_item_${0..1}"),
DATABASE_STRATEGY(TYPE=standard,SHARDING_COLUMN=user_id,SHARDING_ALGORITHM=database_inline),
TABLE_STRATEGY(TYPE=standard,SHARDING_COLUMN=order_id,SHARDING_ALGORITHM=t_order_item_inline),
-GENERATED_KEY(COLUMN=order_item_id,TYPE(NAME=snowflake,PROPERTIES("worker-id"=123)))
+GENERATED_KEY(COLUMN=order_item_id,TYPE(NAME=snowflake))
);
```