public class ConfigWatch extends Object implements Closeable, org.springframework.context.ApplicationEventPublisherAware
构造器和说明 |
---|
ConfigWatch(ConsulConfigProperties properties,
com.ecwid.consul.v1.ConsulClient consul,
LinkedHashMap<String,Long> initialIndexes) |
ConfigWatch(ConsulConfigProperties properties,
List<String> contexts,
com.ecwid.consul.v1.ConsulClient consul)
已过时。
|
限定符和类型 | 方法和说明 |
---|---|
void |
close() |
void |
setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher publisher) |
void |
start() |
void |
watchConfigKeyValues() |
@Deprecated public ConfigWatch(ConsulConfigProperties properties, List<String> contexts, com.ecwid.consul.v1.ConsulClient consul)
public ConfigWatch(ConsulConfigProperties properties, com.ecwid.consul.v1.ConsulClient consul, LinkedHashMap<String,Long> initialIndexes)
public void setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher publisher)
setApplicationEventPublisher
在接口中 org.springframework.context.ApplicationEventPublisherAware
@PostConstruct public void start()
@Scheduled(fixedDelayString="${spring.cloud.consul.config.watch.delay:1000}") public void watchConfigKeyValues()
public void close()
close
在接口中 Closeable
close
在接口中 AutoCloseable
Copyright © 2018 Pivotal Software, Inc.. All rights reserved.