类 SmartConfigurationPropertiesRebinder

java.lang.Object
org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder
com.alibaba.cloud.nacos.refresh.SmartConfigurationPropertiesRebinder
所有已实现的接口:
EventListener, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.cloud.context.environment.EnvironmentChangeEvent>

public class SmartConfigurationPropertiesRebinder extends org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder
Extend ConfigurationPropertiesRebinder.

Spring team doesn't seem to support single ConfigurationPropertiesBean refresh.

SmartConfigurationPropertiesRebinder can refresh specific ConfigurationPropertiesBean base on the change keys.

NOTE: We still use Spring's default behavior (full refresh) as default behavior, This feature can be considered an advanced feature, it may not be as stable as the default behavior.

从以下版本开始:
2021.0.1.1
作者:
freeman
  • 构造器概要

    构造器
    构造器
    说明
    SmartConfigurationPropertiesRebinder(org.springframework.cloud.context.properties.ConfigurationPropertiesBeans beans)
     
  • 方法概要

    修饰符和类型
    方法
    说明
    void
    onApplicationEvent(org.springframework.cloud.context.environment.EnvironmentChangeEvent event)
     
    void
    setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
     

    从类继承的方法 org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder

    getBeanNames, getErrors, getNeverRefreshable, rebind, rebind, rebind

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    从接口继承的方法 org.springframework.context.ApplicationListener

    supportsAsyncExecution
  • 构造器详细资料

    • SmartConfigurationPropertiesRebinder

      public SmartConfigurationPropertiesRebinder(org.springframework.cloud.context.properties.ConfigurationPropertiesBeans beans)
  • 方法详细资料

    • setApplicationContext

      public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
      指定者:
      setApplicationContext 在接口中 org.springframework.context.ApplicationContextAware
      覆盖:
      setApplicationContext 在类中 org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder
      抛出:
      org.springframework.beans.BeansException
    • onApplicationEvent

      public void onApplicationEvent(org.springframework.cloud.context.environment.EnvironmentChangeEvent event)
      指定者:
      onApplicationEvent 在接口中 org.springframework.context.ApplicationListener<org.springframework.cloud.context.environment.EnvironmentChangeEvent>
      覆盖:
      onApplicationEvent 在类中 org.springframework.cloud.context.properties.ConfigurationPropertiesRebinder