You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "ev1lQuark (via GitHub)" <gi...@apache.org> on 2023/04/23 04:00:27 UTC

[GitHub] [dubbo-go] ev1lQuark opened a new issue, #2308: The configuration file extension only supports yaml but not yml

ev1lQuark opened a new issue, #2308:
URL: https://github.com/apache/dubbo-go/issues/2308

   ### Environment
   
   - Server: Dubbo-go, v3.0.5
   - Client: Dubbo-go, v3.0.5
   - Protocol: Triple
   - Registry: Nacos, v2.0.0
   
   ### Issue description
   
   The configuration file extension only supports yaml but not yml, but some examples under dubbo-go-samples use yml as configuration file extension. So should we consider adding support for the yml file extension?
   
   配置文件扩展名只支持 yaml,不支持 yml,但是 dubbo-go-samples 下的一些例子使用 yml 作为配置文件扩展名。那么我们是否应该考虑添加对 yml 文件扩展名的支持?
   
   ### Logs
   
   <details><summary>Click me to check logs</summary>
   
   ```
   Panic:
   "open D:\\repo\\dubbo-go-samples\\helloworld\\go-server\\conf\\dubbog...
   Stack:
   	2  0x00000000018baa09 in dubbo.apache.org/dubbo-go/v3/config.NewLoaderConf
   	    at D:/repo/dubbo-go/config/config_loader_options.go:70
   	3  0x00000000018b9387 in dubbo.apache.org/dubbo-go/v3/config.Load
   	    at D:/repo/dubbo-go/config/config_loader.go:47
   	4  0x0000000002bf7b11 in main.main
   	    at D:/repo/dubbo-go-samples/helloworld/go-server/cmd/server.go:84
   ```
   
   </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.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


[GitHub] [dubbo-go] zhaoyunxing92 commented on issue #2308: The configuration file extension only supports yaml but not yml

Posted by "zhaoyunxing92 (via GitHub)" <gi...@apache.org>.
zhaoyunxing92 commented on issue #2308:
URL: https://github.com/apache/dubbo-go/issues/2308#issuecomment-1536393277

   yaml和 yml 文件都可以没有区分的:[config_resolver](https://github.com/apache/dubbo-go/blob/main/config/config_resolver.go#L60-L70)


-- 
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


[GitHub] [dubbo-go] ev1lQuark commented on issue #2308: The configuration file extension only supports yaml but not yml

Posted by "ev1lQuark (via GitHub)" <gi...@apache.org>.
ev1lQuark commented on issue #2308:
URL: https://github.com/apache/dubbo-go/issues/2308#issuecomment-1535795836

   Sorry, there was a mistake in my previous description. After looking at the code related to configuration loading, it is indeed possible to support multiple types of configuration files by setting environment variables. However, some of the configuration files for samples in dubbo-go-samples are in yml format, and testing these samples requires setting environment variables or manually changing the file extension to yaml. Perhaps we can standardize the configuration file examples in samples as yaml or optimize the dubbo-go loading process to treat yaml and yml formats equally, which would reduce the difficulty for users to get started.
   
   抱歉,之前的描述存在问题。我又看了一下配置加载相关的代码,的确可以通过设置环境变量支持多种配置文件类型。但 dubbo-go-samples 的一些 samples 的配置文件为 yml,测试该 samples 需要设置环境变量或者手动修改文件后缀名为 yaml。或许可以约束 samples 中的配置文件示例为 yaml,或者优化 dubbo-go 的加载过程对于 yaml 和 yml 不做区分,降低用户上手难度。


-- 
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


[GitHub] [dubbo-go] zhaoyunxing92 commented on issue #2308: The configuration file extension only supports yaml but not yml

Posted by "zhaoyunxing92 (via GitHub)" <gi...@apache.org>.
zhaoyunxing92 commented on issue #2308:
URL: https://github.com/apache/dubbo-go/issues/2308#issuecomment-1519045453

   "json", "toml", "yaml", "yml", "properties"  支持的配置文件类型


-- 
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


[GitHub] [dubbo-go] justxuewei commented on issue #2308: The configuration file extension only supports yaml but not yml

Posted by "justxuewei (via GitHub)" <gi...@apache.org>.
justxuewei commented on issue #2308:
URL: https://github.com/apache/dubbo-go/issues/2308#issuecomment-1518968403

   @zhaoyunxing92 Please take a look.


-- 
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