From 5422101aa69e878d726dd8555894f6d544e135d2 Mon Sep 17 00:00:00 2001 From: CherishCai <785427346@qq.com> Date: Fri, 29 Sep 2023 19:19:35 +0800 Subject: [PATCH 1/2] bump: upgrade version 0.3.2 --- CHANGELOG.md | 14 ++++++++++++++ Cargo.toml | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d1bd3a0..02ed262 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,19 @@ # 变更日志 | Change log +### 0.3.2 + +- 增强:支持环境变量设置部分参数,默认为环境变量优先 +- 增强:提供防推空参数设置,默认 true +- 增强:支持 server_addr 不设置端口,默认 8848 +- 测试:Integration Test with nacos-server + +--- + +- Enhance: Read props from environment variables +- Enhance: The `naming_push_empty_protection` count be set by ClientProps +- Enhance: Support `server-addr` without port, default 8848 +- Test:Integration Test with nacos-server + ### 0.3.1 - Fix:异步登陆未完成,进行其它调用出现未登陆异常 `user not found` diff --git a/Cargo.toml b/Cargo.toml index 2e1ac72..fc59d8b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,7 +18,7 @@ [package] name = "nacos-sdk" -version = "0.3.1" +version = "0.3.2" edition = "2021" authors = ["nacos-group", "CheirshCai <785427346@qq.com>", "onewe <2583021406@qq.com>"] license = "Apache-2.0" From 73f646d0044acdc42d0ca3e3f0ea1114b9963e1a Mon Sep 17 00:00:00 2001 From: CherishCai <785427346@qq.com> Date: Fri, 29 Sep 2023 19:37:29 +0800 Subject: [PATCH 2/2] doc: Props doc in README.md --- CHANGELOG.md | 4 ++-- README.md | 7 +++++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 02ed262..861a708 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,8 +9,8 @@ --- -- Enhance: Read props from environment variables -- Enhance: The `naming_push_empty_protection` count be set by ClientProps +- Enhance: Read props from environment variables, please see `nacos_sdk::api::constants::ENV_NACOS_CLIENT_*` +- Enhance: The `naming_push_empty_protection` could be set by ClientProps - Enhance: Support `server-addr` without port, default 8848 - Test:Integration Test with nacos-server diff --git a/README.md b/README.md index 36a5f1c..8a55db2 100644 --- a/README.md +++ b/README.md @@ -111,6 +111,13 @@ nacos-sdk = { version = "0.3", features = ["default"] } ); ``` +### Props +Props count be set by `ClientProps`, or Environment variables (Higher priority). +See them in `nacos_sdk::api::props::ClientProps` or `nacos_sdk::api::constants::ENV_NACOS_CLIENT_*`. +e.g. +- env `NACOS_CLIENT_COMMON_THREAD_CORES` to set num when multi-cpus, default is num_cpus +- env `NACOS_CLIENT_NAMING_PUSH_EMPTY_PROTECTION` for naming empty data notify protection, default true + ## 开发说明 - Build with `cargo build` - Test with `cargo test`