You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "CAICAIIs (via GitHub)" <gi...@apache.org> on 2025/08/18 16:01:47 UTC
[PR] config: implement dynamic logger level update [dubbo-go]
CAICAIIs opened a new pull request, #2978:
URL: https://github.com/apache/dubbo-go/pull/2978
(no comment)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "CAICAIIs (via GitHub)" <gi...@apache.org>.
CAICAIIs closed pull request #2978: config: implement dynamic logger level update
URL: https://github.com/apache/dubbo-go/pull/2978
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3240208244
## [Codecov](https://app.codecov.io/gh/apache/dubbo-go/pull/2978?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:x: Patch coverage is `72.72727%` with `3 lines` in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 39.61%. Comparing base ([`60d1c2a`](https://app.codecov.io/gh/apache/dubbo-go/commit/60d1c2a949f0ee0da4be3fe09fb79d295491e040?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`7add867`](https://app.codecov.io/gh/apache/dubbo-go/commit/7add86746ba71bb2601a4a0d8ff80e18b18940da?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 617 commits behind head on develop.
| [Files with missing lines](https://app.codecov.io/gh/apache/dubbo-go/pull/2978?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [config/logger\_config.go](https://app.codecov.io/gh/apache/dubbo-go/pull/2978?src=pr&el=tree&filepath=config%2Flogger_config.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-Y29uZmlnL2xvZ2dlcl9jb25maWcuZ28=) | 72.72% | [1 Missing and 2 partials :warning: ](https://app.codecov.io/gh/apache/dubbo-go/pull/2978?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## develop #2978 +/- ##
===========================================
- Coverage 46.76% 39.61% -7.16%
===========================================
Files 295 457 +162
Lines 17172 38872 +21700
===========================================
+ Hits 8031 15400 +7369
- Misses 8287 22210 +13923
- Partials 854 1262 +408
```
</details>
[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/dubbo-go/pull/2978?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "CAICAIIs (via GitHub)" <gi...@apache.org>.
CAICAIIs commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3197582643
Related to #1980
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "AlexStocks (via GitHub)" <gi...@apache.org>.
AlexStocks commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3240896621
> I believe the issue #1980 will be resolved with #2992.
没明白,那这个 PR 还要不要?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "marsevilspirit (via GitHub)" <gi...@apache.org>.
marsevilspirit commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3240839455
I believe the issue #1980 will be resolved with #2992.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3197523668
## [](https://sonarcloud.io/dashboard?id=apache_dubbo-go&pullRequest=2978) **Quality Gate passed**
Issues
 [0 New issues](https://sonarcloud.io/project/issues?id=apache_dubbo-go&pullRequest=2978&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_dubbo-go&pullRequest=2978&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_dubbo-go&pullRequest=2978&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_dubbo-go&pullRequest=2978&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_dubbo-go&pullRequest=2978&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_dubbo-go&pullRequest=2978)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3240205775
## [](https://sonarcloud.io/dashboard?id=apache_dubbo-go&pullRequest=2978) **Quality Gate passed**
Issues
 [0 New issues](https://sonarcloud.io/project/issues?id=apache_dubbo-go&pullRequest=2978&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_dubbo-go&pullRequest=2978&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_dubbo-go&pullRequest=2978&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_dubbo-go&pullRequest=2978&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_dubbo-go&pullRequest=2978&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_dubbo-go&pullRequest=2978)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "marsevilspirit (via GitHub)" <gi...@apache.org>.
marsevilspirit commented on PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#issuecomment-3240905454
> > I believe the issue #1980 will be resolved with #2992.
>
> 没明白,那这个 PR 还要不要?
不需要这个pr, 这个是config热更新该做的事
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "AlexStocks (via GitHub)" <gi...@apache.org>.
AlexStocks commented on code in PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#discussion_r2312491365
##########
config/logger_config.go:
##########
@@ -117,7 +118,17 @@ func (l *LoggerConfig) toURL() *common.URL {
// DynamicUpdateProperties dynamically update properties.
func (l *LoggerConfig) DynamicUpdateProperties(new *LoggerConfig) {
Review Comment:
do not use Golang key word 'new' as variable name
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#discussion_r2312491054
##########
config/logger_config_test.go:
##########
@@ -27,6 +27,11 @@ import (
"github.com/stretchr/testify/assert"
)
+import (
+ cfgcenter "dubbo.apache.org/dubbo-go/v3/config_center"
+ dlogger "dubbo.apache.org/dubbo-go/v3/logger"
+)
Review Comment:
The second import block should be merged with the existing import block above (lines 25-28) to follow Go's standard import grouping conventions.
##########
config/logger_config_test.go:
##########
@@ -83,3 +88,62 @@ func TestNewLoggerConfigBuilder(t *testing.T) {
assert.Equal(t, *config.File.Compress, true)
assert.Equal(t, config.File.MaxBackups, 5)
}
+
+func TestLoggerDynamicUpdateLevel(t *testing.T) {
+ // load initial config from bytes
+ initialYAML := `
+ dubbo:
+ logger:
+ driver: zap
+ level: info
+ `
+ err := Load(WithBytes([]byte(initialYAML)))
+ assert.Nil(t, err)
+ assert.NotNil(t, rootConfig)
+ assert.NotNil(t, rootConfig.Logger)
+ assert.Equal(t, "info", rootConfig.Logger.Level)
+
+ // if runtime logger doesn't support dynamic level, skip this test
+ if !dlogger.SetLoggerLevel(rootConfig.Logger.Level) {
Review Comment:
Using `SetLoggerLevel` with the current level ('info') to test dynamic level support is incorrect. This should test with a different level or use a dedicated method to check if dynamic level changes are supported, as setting the same level may always return true regardless of actual dynamic support.
```suggestion
// test dynamic level support by attempting to set a different level
if !dlogger.SetLoggerLevel("debug") {
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] config: implement dynamic logger level update [dubbo-go]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #2978:
URL: https://github.com/apache/dubbo-go/pull/2978#discussion_r2312505170
##########
config/logger_config_test.go:
##########
@@ -27,6 +27,11 @@ import (
"github.com/stretchr/testify/assert"
)
+import (
+ cfgcenter "dubbo.apache.org/dubbo-go/v3/config_center"
+ dlogger "dubbo.apache.org/dubbo-go/v3/logger"
+)
Review Comment:
This import block should be merged with the existing import block above (lines 24-28) to follow Go conventions of having a single import block per file.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org