spring-cloud / spring-cloud-bus

Spring Cloud event bus
http://cloud.spring.io/spring-cloud-bus/
Apache License 2.0
408 stars 242 forks source link

bus refresh not working when using config server with spring active profiles #266

Closed iqdeepak closed 1 year ago

iqdeepak commented 1 year ago

Describe the bug I have created a config server and client and also implemented monitor endpoint and it was working fine till the time i havent used spring profile but after using spring profile i am also geting below error in config server logs when updating the property in git repo:

Refresh for: :ge4 2023-04-30 17:45:08.294 INFO 24636 --- [nio-8080-exec-9] o.s.cloud.bus.event.RefreshListener : Received remote refresh request. 2023-04-30 17:45:08.294 INFO 24636 --- [nio-8080-exec-9] o.s.cloud.bus.event.RefreshListener : Refresh not performed, the event was targeting :ge4:**

Sample client: application-ge4.properties: spring.application.name=oep_df-fsl-consumer spring.cloud.config.name=oep_df_fsl_consumer spring.profile.active=ge4 spring.config.import=optional:configserver:http://localhost:8080 spring.cloud.bus.enabled=true

Rabbit mq properties

spring.rabbitmq.host=dummy spring.rabbitmq.virtual-host=dummy spring.rabbitmq.port=8071 spring.rabbitmq.username=Americas\dummy spring.rabbitmq.ssl.enabled=false spring.rabbitmq.ssl.algorithm=TLSv1.2 spring.rabbitmq.password=dummy spring.cloud.bus.enabled=true


server: application-dev.properties

Rabbit mq properties

spring.rabbitmq.host=dummy spring.rabbitmq.virtual-host=dummy spring.rabbitmq.port=8071 spring.rabbitmq.username=Americas\dummy spring.rabbitmq.ssl.enabled=false spring.rabbitmq.ssl.algorithm=TLSv1.2 spring.rabbitmq.password=dummy spring.cloud.bus.enabled=true

server: bootstrap.yml: management: security: enabled: false

health: config: enabled: false

spring: application: name: configServer cloud: config: server: encrypt: enabled: false git: type: native uri: git@gitlab..com:omicrofrontend/backend-config-server-configurations.git default-label: dev searchPaths: oep*,oep_df_fsl_consumer ignore-local-ssh-settings: true passphrase: dummy preferredAuthentications: publickey cloneOnStart: true privateKey: | -----BEGIN RSA PRIVATE KEY----- Proc-Type: 4,ENCRYPTED

        hfHDUS9giwMMqCE7eXkHdMZFY2vRiCOn5skJafBL+57gdvA660fjDwFa5AP0hAyZ
        -----END RSA PRIVATE KEY-----

        folder str in git repor
        oep_df_fsl_consumer
                          -application-ge4.properties
                          -application-ge2.properties

i understood the issue by seeing the link on it that it is regarding the serviceid matcher class and default id method. but i dont know how to override all these methods and all. Can you tell some easy solution.

ryanjbaxter commented 1 year ago

Can you provide a complete, minimal, verifiable sample that reproduces the problem? It should be available as a GitHub (or similar) project or attached to this issue as a zip file.

i understood the issue by seeing the link on it that it is regarding the serviceid matcher class and default id method. but i dont know how to override all these methods and all.

I am unsure what you are referring to

spring-cloud-issues commented 1 year ago

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

spring-cloud-issues commented 1 year ago

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.