This is an automated email from the ASF dual-hosted git repository.
albumenj pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo-website.git
The following commit(s) were added to refs/heads/master by this push:
new 0488da5 [3.0] Nacos config center (#837)
0488da5 is described below
commit 0488da5f2ffceebae83a5f2ae807fa5dc7b8e353
Author: 赵延 <[email protected]>
AuthorDate: Thu Jun 24 15:54:06 2021 +0800
[3.0] Nacos config center (#837)
* Some typo and error link fix.
* complete nacos-dynamic-config center.
* add comma for namespace,dataId,group
---
content/zh/docs/v2.7/dev/impls/config-center.md | 2 +-
.../v3.0/references/configuration/config-center.md | 41 ++++++++++++++++++---
.../zh/docs/v3.0/references/spis/config-center.md | 2 +-
.../nacos-configcenter-application-properties.png | Bin 0 -> 155792 bytes
.../user/nacos-configcenter-global-properties.png | Bin 0 -> 166881 bytes
static/imgs/user/nacos-configcenter-governance.png | Bin 0 -> 192062 bytes
6 files changed, 37 insertions(+), 8 deletions(-)
diff --git a/content/zh/docs/v2.7/dev/impls/config-center.md
b/content/zh/docs/v2.7/dev/impls/config-center.md
index 8602e26..90d192f 100644
--- a/content/zh/docs/v2.7/dev/impls/config-center.md
+++ b/content/zh/docs/v2.7/dev/impls/config-center.md
@@ -1,6 +1,6 @@
---
type: docs
-title: "Dubbo 配置中心扩展"
+title: "配置中心扩展"
linkTitle: "配置中心扩展"
weight: 13
---
diff --git a/content/zh/docs/v3.0/references/configuration/config-center.md
b/content/zh/docs/v3.0/references/configuration/config-center.md
index 2e6e346..df387cb 100644
--- a/content/zh/docs/v3.0/references/configuration/config-center.md
+++ b/content/zh/docs/v3.0/references/configuration/config-center.md
@@ -61,7 +61,7 @@ dubbo.application.qos.port=33333
- 作用域
-
外部化配置有全局和应用两个级别,全局配置是所有应用共享的,应用级配置是由每个应用自己维护且只对自身可见的。当前已支持的扩展实现有Zookeeper、Apollo。
+
外部化配置有全局和应用两个级别,全局配置是所有应用共享的,应用级配置是由每个应用自己维护且只对自身可见的。当前已支持的扩展实现有Zookeeper、Apollo、Nacos。
#### Zookeeper
@@ -103,6 +103,22 @@ Apollo中的一个核心概念是命名空间 - namespace(和上面zookeeper
> 关于文件配置托管,相当于是把 `dubbo.properties` 配置文件的内容存储在了 Apollo 中,应用通过关联共享的 `dubbo`
> namespace 继承公共配置,
> 应用也可以按照 Apollo 的做法来覆盖个别配置项。
+#### Nacos
+```xml
+<dubbo:config-center
address="nacos://127.0.0.1:8848?username=nacos&password=nacos">
+</dubbo:config-center>
+```
+
+Nacos虽然也存在命名空间 - namespace 的概念,但在 namespace 之下,还存在 group 概念。即通过 namespace 和
group 以及 dataId 去定位一个配置项,在不指定 namespace 的情况下,默认使用 `public` 作为默认的命名空间。
+
+在默认情况下,全局配置会读取 namespace : `public`,dataId: `dubbo.properties`,group: `dubbo`
配置项中的内容作为全局配置。应用级别的 group 和全局级别的 group 存在一点差异, 应用级别会读取 namespace:
`public`,dataId: `dubbo.properties`,group: `your application name` 作为应用级别的配置。
+
+全局:
+
+
+应用级别:
+
+
#### 自己加载外部化配置
@@ -120,7 +136,6 @@ configCenter.setExternalConfig(dubboConfigurations);
```
-
## 服务治理
#### Zookeeper
@@ -132,9 +147,7 @@ configCenter.setExternalConfig(dubboConfigurations);
- namespace,用于不同配置的环境隔离。
- config,Dubbo 约定的固定节点,不可更改,所有配置和服务治理规则都存储在此节点下。
- dubbo,所有服务治理规则都是全局性的,dubbo 为默认节点
-- configurators/tag-router/condition-router,不同的服务治理规则类型,node value 存储具体规则内容
-
-
+- configurators/tag-router/condition-router/migration,不同的服务治理规则类型,node value
存储具体规则内容
#### Apollo
@@ -146,4 +159,20 @@ configCenter.setExternalConfig(dubboConfigurations);
- configurators,[覆盖规则](../../examples/config-rule)
- tag-router,[标签路由](../../examples/routing-rule)
-- condition-router,[条件路由](../../examples/routing-rule)
\ No newline at end of file
+- condition-router,[条件路由](../../examples/condition-router)
+- migration, [迁移规则](../../examples/todo)
+
+#### Nacos
+
+所有的服务治理规则都是全局的,默认从 namespace: `public` 下进行读取, 通过 dataId: `interface name` 以及
group: `dubbo` 去读取和订阅:
+
+
+
+不同的规则以 dataId 的后缀区分:
+
+- configurators,[覆盖规则](../../examples/config-rule)
+- tag-router,[标签路由](../../examples/routing-rule)
+- condition-router,[条件路由](../../examples/condition-router)
+- migration, [迁移规则](../../examples/todo)
+
+
diff --git a/content/zh/docs/v3.0/references/spis/config-center.md
b/content/zh/docs/v3.0/references/spis/config-center.md
index 8602e26..90d192f 100644
--- a/content/zh/docs/v3.0/references/spis/config-center.md
+++ b/content/zh/docs/v3.0/references/spis/config-center.md
@@ -1,6 +1,6 @@
---
type: docs
-title: "Dubbo 配置中心扩展"
+title: "配置中心扩展"
linkTitle: "配置中心扩展"
weight: 13
---
diff --git a/static/imgs/user/nacos-configcenter-application-properties.png
b/static/imgs/user/nacos-configcenter-application-properties.png
new file mode 100644
index 0000000..a5b93d9
Binary files /dev/null and
b/static/imgs/user/nacos-configcenter-application-properties.png differ
diff --git a/static/imgs/user/nacos-configcenter-global-properties.png
b/static/imgs/user/nacos-configcenter-global-properties.png
new file mode 100644
index 0000000..6d4772e
Binary files /dev/null and
b/static/imgs/user/nacos-configcenter-global-properties.png differ
diff --git a/static/imgs/user/nacos-configcenter-governance.png
b/static/imgs/user/nacos-configcenter-governance.png
new file mode 100644
index 0000000..f49f80f
Binary files /dev/null and b/static/imgs/user/nacos-configcenter-governance.png
differ