!28 更新nacos-config-spring-boot版本,以解决Receiver被提前初始化的问题

Merge pull request !28 from 小宇宙/master
master
Java3y 3 years ago committed by Gitee
commit 9ccf9194b2
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

@ -36,9 +36,6 @@ public class ReceiverStart {
@Autowired
private ConsumerFactory consumerFactory;
@Value("${austin.nacos.enabled}")
private Boolean nacosEnabled;
/**
* receiver
*/
@ -59,13 +56,7 @@ public class ReceiverStart {
*/
@PostConstruct
public void init() {
int total = groupIds.size();
if (nacosEnabled) {
// 当nacos开启时 会导致Receiver提前加载 所以这里getBean次数-1
// nacos issue: https://github.com/nacos-group/nacos-spring-project/issues/249
total -= 1;
}
for (int i = 0; i < total; i++) {
for (int i = 0; i < groupIds.size(); i++) {
context.getBean(Receiver.class);
}
}

@ -89,7 +89,7 @@
<dependency>
<groupId>com.alibaba.boot</groupId>
<artifactId>nacos-config-spring-boot-starter</artifactId>
<version>0.2.1</version>
<version>0.2.12</version>
</dependency>
<!--apollo-->

Loading…
Cancel
Save