yhs0092 commented on a change in pull request #104: 配置注入的文档实现修改
URL: https://github.com/apache/servicecomb-docs/pull/104#discussion_r288382686
##########
File path: java-chassis-reference/zh_CN/config/inject-config.md
##########
@@ -75,13 +75,18 @@ ConfigNoAnnotation config = new
ConfigObjectFactory().create(ConfigNoAnnotation.
2. root.l1-2
```Java
-ConfigWithAnnotation config = new
ConfigObjectFactory().create(ConfigWithAnnotation.class,
+ConfigWithAnnotation config =
SCBEngine.getInstance().getPriorityPropertyManager().createConfigObject(ConfigWithAnnotation.class,
"key", "k",
"low-list", Arrays.asList("low-1", "low-2"),
"high-list", Arrays.asList("high-1", "high-2"),
"full-list", Arrays.asList("l1-1", "l1-2")
);
```
+最后不管是有无注解的属性注入,都要显示的回收对象PriorityPropertyManager
Review comment:
都要"显式地"回收配置注入对象
fix typo, and the objects should be collected are the injected ConfigObject
instances, instead of the `PriorityPropertyManager`
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services