/env/reset 和 /refresh 之间的区别
Difference between /env/reset and /refresh
例如,我有一个刚刚更新了一些 属性 的配置服务器。我应该 运行 /env/reset
还是 /refresh
在客户端或两者上?
根据 Spring 文档,功能似乎重叠。
POST to /env to update the Environment and rebind
@ConfigurationProperties and log levels
/refresh for re-loading the boot strap context and refreshing the
@RefreshScope beans
如果我有 @RefreshScope
和 @ConfigurationProperties
会怎样?这是一个糟糕的设计吗?
查看源代码:
/env/reset 将重置通过
POST 请求 /env.
/refresh 将从配置服务器中提取新属性并重新绑定
它们与@RefreshScope beans.
在 Spring 启动 1.5.13
例如,我有一个刚刚更新了一些 属性 的配置服务器。我应该 运行 /env/reset
还是 /refresh
在客户端或两者上?
根据 Spring 文档,功能似乎重叠。
POST to /env to update the Environment and rebind @ConfigurationProperties and log levels
/refresh for re-loading the boot strap context and refreshing the @RefreshScope beans
如果我有 @RefreshScope
和 @ConfigurationProperties
会怎样?这是一个糟糕的设计吗?
查看源代码:
/env/reset 将重置通过 POST 请求 /env.
/refresh 将从配置服务器中提取新属性并重新绑定 它们与@RefreshScope beans.
在 Spring 启动 1.5.13