由于作者已经不再维护这个项目,所以有问题只能自己改源码来修复了。
改动点:
com.baidu.disconf.client.addons.properties.ReloadingPropertyPlaceholderConfigurer第97行:
// then, business as usual. no recursive reloading placeholders please.
return super.parseStringValue(buf.toString(), props, visitedPlaceholders);
改为:
// Fixed an issue with using obsolete api, which can't be started in spring5.
// then, business as usual. no recursive reloading placeholders please.PropertyPlaceholderHelper helper = new PropertyPlaceholderHelper(placeholderPrefix, placeholderSuffix, valueSeparator, ignoreUnresolvablePlaceholders);
return helper.replacePlaceholders(strVal, props);
GitHub地址:https://github.com/cjbi/disconf