Environment:

Spring Boot: 2.4.2 Spring Cloud: 2020.0.0

Spring cloud config server configuration for service configuration repository

spring:
  cloud:
    config:
      server:
        git:
          repos:
            service:
              uri: ssh://${git.url}/service-config.git/

Repository service-config.git has following structure of files on master branch:

application.yml
service-alfa.yml
service-beta.yml

Using spring boot 2.4.1 config service returns properties using following url: https://${configServiceUrl}/service/alfa

{
  "name": "service",
  "profiles": [
    "alfa"
  ],
  "label": null,
  "state": null,
  "propertySources": [
    {
      "name": "ssh://git.url/service_config.git//service-alfa.yml",
      "source": {
        "property": "value"
      }
    },
    {
      "name": "ssh://git.url/service_config.git//application.yml",
      "source": {
        "pro": "val"
      }
    }
  ]
}

but after upgrade to 2.4.2 spring cloud config service does not return properties and no exception is thrown like:

{
  "name": "service",
  "profiles": [
    "alfa"
  ],
  "label": null,
  "state": null,
  "propertySources": []
}

Based on release notes I can see that this change https://github.com/spring-projects/spring-boot/issues/24504 could introduce such behaviour.

Comment From: snicoll

@kboczek Spring Boot 2.4.x is out of OSS support so please upgrade first to a supported version. If you can still experience the problem at that point, we'll need a bit more detail to investigate.

Comment From: kboczek

Thank you @snicoll for the reply. I forgot to mention that at first I upgraded to the latest spring boot version 2.6.7 with latest spring cloud 2021.0.1 and then start to downgrade version by version to see from which version this behaviour was introduced. In the meantime I found the solution. I have removed spring.profiles.active=alfa property from service-alfa.yml and then config service start to serve properties the same as with spring boot 2.4.1 version. I found that it is related to https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide. Im closing the issue and sorry for bothering you