Spring云配置+;春云巴士+;RabbitMQ-不使用本地Git存储库自动刷新客户端

Spring云配置+;春云巴士+;RabbitMQ-不使用本地Git存储库自动刷新客户端,spring,spring-cloud,spring-cloud-config,spring-cloud-bus,Spring,Spring Cloud,Spring Cloud Config,Spring Cloud Bus,我有一些应用程序从Spring云配置服务器(Brixton.RELEASE)获取其配置,并希望启用其属性的自动刷新。我已经按照SpringCloud配置来配置服务器和客户端应用程序,但是,当对本地git文件进行更改时,什么都没有发生 默认配置还检测本地git中的文件系统更改 存储库(在这种情况下不使用webhook,但只要您 编辑配置文件(将广播刷新) 有人能指出哪里可能出错,或者在SpringCloud的代码中调试到哪里来检查它吗 Spring云服务器配置: server: port: 8

我有一些应用程序从Spring云配置服务器(Brixton.RELEASE)获取其配置,并希望启用其属性的自动刷新。我已经按照SpringCloud配置来配置服务器和客户端应用程序,但是,当对本地git文件进行更改时,什么都没有发生

默认配置还检测本地git中的文件系统更改 存储库(在这种情况下不使用webhook,但只要您 编辑配置文件(将广播刷新)

有人能指出哪里可能出错,或者在SpringCloud的代码中调试到哪里来检查它吗

Spring云服务器配置

server:
  port: 8888

info:
  description: Spring Cloud Config Server

spring:
  application:
    name: config-server
  cloud:
    config:
      server:
        git:
          uri: file:///C:/Users/myuser/git/config-dev/
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusInput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusOutput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel errorChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel nullChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.s.binding.BindableProxyFactory     : Binding outputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusOutput
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@707ca986: startup date [Fri May 13 10:03:10 CEST 2016]; root of context hierarchy
trationDelegate$BeanPostProcessorChecker : Bean 'configurationPropertiesRebinderAutoConfiguration' of type [class org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$73faa1d3] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
o.s.cloud.commons.util.InetUtils         : Cannot determine local hostname
e.m.a.config.ConfigServerApplication     : No active profile set, falling back to default profiles: default
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@1ca610a0: startup date [Fri May 13 10:03:11 CEST 2016]; parent: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@294a6b8e
o.s.c.support.GenericApplicationContext  : Refreshing org.springframework.context.support.GenericApplicationContext@6048e26a: startup date [Fri May 13 10:03:11 CEST 2016]; root of context hierarchy
e.m.a.config.ConfigServerApplication     : Started ConfigServerApplication in 2.907 seconds (JVM running for 12.366)
o.s.a.r.c.CachingConnectionFactory       : Created new connection: SimpleConnection@7bbcf6f0 [delegate=amqp://guest@127.0.0.1:5672/]
o.s.i.endpoint.EventDrivenConsumer       : Adding {message-handler:outbound.springCloudBus} as a subscriber to the 'springCloudBusOutput' channel
o.s.integration.channel.DirectChannel    : Channel 'config-server:8888.springCloudBusOutput' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started outbound.springCloudBus
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 0
o.s.i.endpoint.EventDrivenConsumer       : Adding {logging-channel-adapter:_org.springframework.integration.errorLogger} as a subscriber to the 'errorChannel' channel
o.s.i.channel.PublishSubscribeChannel    : Channel 'config-server:8888.errorChannel' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started _org.springframework.integration.errorLogger
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 2147482647
o.s.c.s.binding.BindableProxyFactory     : Binding inputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusInput
o.s.c.s.b.r.RabbitMessageChannelBinder   : declaring queue for inbound: springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg, bound to: springCloudBus
o.s.integration.channel.DirectChannel    : Channel 'springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg.bridge' has 1 subscriber(s).
o.s.i.a.i.AmqpInboundChannelAdapter      : started inbound.springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    </dependency>

    <dependency>
        <groupId>javax.validation</groupId>
        <artifactId>validation-api</artifactId>
        <version>1.1.0.Final</version>
    </dependency>

    <dependency>
        <groupId>org.hibernate</groupId>
        <artifactId>hibernate-validator</artifactId>
    </dependency>
spring:
  application:
    name: app
  cloud:
    config:
      uri: http://localhost:8888
o.s.b.a.e.m.EndpointHandlerMapping  INFO - Mapped "{[/bus/refresh],methods=[POST]}" onto public void org.springframework.cloud.bus.endpoint.RefreshBusEndpoint.refresh(java.lang.String)
...
o.s.i.m.IntegrationMBeanExporter  INFO - Registering beans for JMX exposure on startup
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusInput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusOutput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel nullChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel errorChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.b.a.e.j.EndpointMBeanExporter  INFO - Registering beans for JMX exposure on startup
Spring云服务器pom.xml

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-config-server</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-config-monitor</artifactId>
    </dependency>

    <dependency>
        <groupId>javax.validation</groupId>
        <artifactId>validation-api</artifactId>
        <version>1.1.0.Final</version>
    </dependency>

    <dependency>
        <groupId>org.hibernate</groupId>
        <artifactId>hibernate-validator</artifactId>
    </dependency>
客户端应用程序pom.xml

server:
  port: 8888

info:
  description: Spring Cloud Config Server

spring:
  application:
    name: config-server
  cloud:
    config:
      server:
        git:
          uri: file:///C:/Users/myuser/git/config-dev/
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusInput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusOutput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel errorChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel nullChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.s.binding.BindableProxyFactory     : Binding outputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusOutput
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@707ca986: startup date [Fri May 13 10:03:10 CEST 2016]; root of context hierarchy
trationDelegate$BeanPostProcessorChecker : Bean 'configurationPropertiesRebinderAutoConfiguration' of type [class org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$73faa1d3] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
o.s.cloud.commons.util.InetUtils         : Cannot determine local hostname
e.m.a.config.ConfigServerApplication     : No active profile set, falling back to default profiles: default
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@1ca610a0: startup date [Fri May 13 10:03:11 CEST 2016]; parent: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@294a6b8e
o.s.c.support.GenericApplicationContext  : Refreshing org.springframework.context.support.GenericApplicationContext@6048e26a: startup date [Fri May 13 10:03:11 CEST 2016]; root of context hierarchy
e.m.a.config.ConfigServerApplication     : Started ConfigServerApplication in 2.907 seconds (JVM running for 12.366)
o.s.a.r.c.CachingConnectionFactory       : Created new connection: SimpleConnection@7bbcf6f0 [delegate=amqp://guest@127.0.0.1:5672/]
o.s.i.endpoint.EventDrivenConsumer       : Adding {message-handler:outbound.springCloudBus} as a subscriber to the 'springCloudBusOutput' channel
o.s.integration.channel.DirectChannel    : Channel 'config-server:8888.springCloudBusOutput' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started outbound.springCloudBus
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 0
o.s.i.endpoint.EventDrivenConsumer       : Adding {logging-channel-adapter:_org.springframework.integration.errorLogger} as a subscriber to the 'errorChannel' channel
o.s.i.channel.PublishSubscribeChannel    : Channel 'config-server:8888.errorChannel' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started _org.springframework.integration.errorLogger
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 2147482647
o.s.c.s.binding.BindableProxyFactory     : Binding inputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusInput
o.s.c.s.b.r.RabbitMessageChannelBinder   : declaring queue for inbound: springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg, bound to: springCloudBus
o.s.integration.channel.DirectChannel    : Channel 'springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg.bridge' has 1 subscriber(s).
o.s.i.a.i.AmqpInboundChannelAdapter      : started inbound.springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    </dependency>

    <dependency>
        <groupId>javax.validation</groupId>
        <artifactId>validation-api</artifactId>
        <version>1.1.0.Final</version>
    </dependency>

    <dependency>
        <groupId>org.hibernate</groupId>
        <artifactId>hibernate-validator</artifactId>
    </dependency>
spring:
  application:
    name: app
  cloud:
    config:
      uri: http://localhost:8888
o.s.b.a.e.m.EndpointHandlerMapping  INFO - Mapped "{[/bus/refresh],methods=[POST]}" onto public void org.springframework.cloud.bus.endpoint.RefreshBusEndpoint.refresh(java.lang.String)
...
o.s.i.m.IntegrationMBeanExporter  INFO - Registering beans for JMX exposure on startup
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusInput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusOutput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel nullChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel errorChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.b.a.e.j.EndpointMBeanExporter  INFO - Registering beans for JMX exposure on startup
客户端应用程序启动日志

server:
  port: 8888

info:
  description: Spring Cloud Config Server

spring:
  application:
    name: config-server
  cloud:
    config:
      server:
        git:
          uri: file:///C:/Users/myuser/git/config-dev/
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusInput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel springCloudBusOutput
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel errorChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Registering MessageChannel nullChannel
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.monitor.IntegrationMBeanExporter   : Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.s.binding.BindableProxyFactory     : Binding outputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusOutput
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@707ca986: startup date [Fri May 13 10:03:10 CEST 2016]; root of context hierarchy
trationDelegate$BeanPostProcessorChecker : Bean 'configurationPropertiesRebinderAutoConfiguration' of type [class org.springframework.cloud.autoconfigure.ConfigurationPropertiesRebinderAutoConfiguration$$EnhancerBySpringCGLIB$$73faa1d3] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
o.s.cloud.commons.util.InetUtils         : Cannot determine local hostname
e.m.a.config.ConfigServerApplication     : No active profile set, falling back to default profiles: default
s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@1ca610a0: startup date [Fri May 13 10:03:11 CEST 2016]; parent: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@294a6b8e
o.s.c.support.GenericApplicationContext  : Refreshing org.springframework.context.support.GenericApplicationContext@6048e26a: startup date [Fri May 13 10:03:11 CEST 2016]; root of context hierarchy
e.m.a.config.ConfigServerApplication     : Started ConfigServerApplication in 2.907 seconds (JVM running for 12.366)
o.s.a.r.c.CachingConnectionFactory       : Created new connection: SimpleConnection@7bbcf6f0 [delegate=amqp://guest@127.0.0.1:5672/]
o.s.i.endpoint.EventDrivenConsumer       : Adding {message-handler:outbound.springCloudBus} as a subscriber to the 'springCloudBusOutput' channel
o.s.integration.channel.DirectChannel    : Channel 'config-server:8888.springCloudBusOutput' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started outbound.springCloudBus
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase -2147482648
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 0
o.s.i.endpoint.EventDrivenConsumer       : Adding {logging-channel-adapter:_org.springframework.integration.errorLogger} as a subscriber to the 'errorChannel' channel
o.s.i.channel.PublishSubscribeChannel    : Channel 'config-server:8888.errorChannel' has 1 subscriber(s).
o.s.i.endpoint.EventDrivenConsumer       : started _org.springframework.integration.errorLogger
o.s.c.support.DefaultLifecycleProcessor  : Starting beans in phase 2147482647
o.s.c.s.binding.BindableProxyFactory     : Binding inputs for :interface org.springframework.cloud.bus.SpringCloudBusClient
o.s.c.s.binding.BindableProxyFactory     : Binding :interface org.springframework.cloud.bus.SpringCloudBusClient:springCloudBusInput
o.s.c.s.b.r.RabbitMessageChannelBinder   : declaring queue for inbound: springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg, bound to: springCloudBus
o.s.integration.channel.DirectChannel    : Channel 'springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg.bridge' has 1 subscriber(s).
o.s.i.a.i.AmqpInboundChannelAdapter      : started inbound.springCloudBus.anonymous.t4cuHSE6RfKRYvPvrgfbUg
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-config</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-bus-amqp</artifactId>
    </dependency>

    <dependency>
        <groupId>javax.validation</groupId>
        <artifactId>validation-api</artifactId>
        <version>1.1.0.Final</version>
    </dependency>

    <dependency>
        <groupId>org.hibernate</groupId>
        <artifactId>hibernate-validator</artifactId>
    </dependency>
spring:
  application:
    name: app
  cloud:
    config:
      uri: http://localhost:8888
o.s.b.a.e.m.EndpointHandlerMapping  INFO - Mapped "{[/bus/refresh],methods=[POST]}" onto public void org.springframework.cloud.bus.endpoint.RefreshBusEndpoint.refresh(java.lang.String)
...
o.s.i.m.IntegrationMBeanExporter  INFO - Registering beans for JMX exposure on startup
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusInput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusInput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusInput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel springCloudBusOutput
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=springCloudBusOutput': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=springCloudBusOutput]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel nullChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=nullChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=nullChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Registering MessageChannel errorChannel
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageChannel,name=errorChannel': registering with JMX server as MBean [org.springframework.integration:type=MessageChannel,name=errorChannel]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=org.springframework.cloud.bus.BusAutoConfiguration.acceptRemote.serviceActivator,bean=endpoint]
o.s.i.m.IntegrationMBeanExporter  INFO - Located managed bean 'org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal': registering with JMX server as MBean [org.springframework.integration:type=MessageHandler,name=errorLogger,bean=internal]
o.s.b.a.e.j.EndpointMBeanExporter  INFO - Registering beans for JMX exposure on startup

请仔细阅读本文档,不要忘记安装ngrock。另外,若您只需要在git提交时刷新,那个么您甚至不需要云总线项目,只要配置就足够了。希望这能有所帮助。

您需要在pom.xml中使用fallowing dependent 编译('org.springframework.cloud:springcloudstreambinder')-Gradle 如果已在另一个系统中安装rabbitmq,则需要在application.properties中指定主机文件


spring.rabbitmq.host:{{hostname}

您需要一个支持spring云总线和rabbitmq(或Kafka或Redis)的配置服务器

。。。
org.springframework.cloud

以及具有配置和RabbitMQ库的客户端应用程序:

...
<dependency>
  <groupId>org.springframework.cloud</groupId>
  <artifactId>spring-cloud-starter-config</artifactId>
</dependency>
<dependency>
  <groupId>org.springframework.cloud</groupId>
  <artifactId>spring-cloud-starter-bus-amqp</artifactId>
</dependency>
...
。。。
org.springframework.cloud

简要说明配置服务器和客户端应用程序的配置、日志和完整源代码。

您提交了更改吗?是的,我也尝试了提交,虽然这不是必需的,但文档声明它只使用本机配置文件检查文件系统,不使用git。@Spencergib I set
spring.application.profiles.active=native
spring.cloud.config.server.native.searchLocations=file:///C:/Users/myuser/git/config-dev/
但仍然没有刷新任何内容。感谢您建议使用ngrok,它帮助我针对一个真正的GitHub repo而不是文件系统进行测试。或者有更好的方法在集群环境中集中JMX管理吗?ootero:我在关注你的博客,并在更改推送到git时刷新我的服务客户端(在本地机器上运行)。我想在pcf上使用相同的概念,即使用pcf rabbitmq服务。如何将pcf服务注入服务客户端。在本地,我配置rabbitmq:rabbitmq:host:。。。。在pcf上,pivotal将rabbitmq放在这个json上:{…凭证:{主机:…..}}