spring-cloud / spring-cloud/spring-cloud-config

Support for dashes in profiles broken

Open
#1,069 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Java
Stars
2k
Forks
1.3k
Avg merge
2d 59m
Merged PRs (30d)
16

Description

I think this might be related to #384:

I've got an application 'foo' which supports two profiles: 'profile1' and 'pro-file2'.

Configuration is served by a configuration-server (Springboot v2.0.3) but this only works without the dash:

  • http://localhost:9001/config/foo-default.json (/)
  • http://localhost:9001/config/foo-profile1.json (/)
  • http://localhost:9001/config/foo-pro-file2.json (x) serves the same as -default.

I build a demo project which demonstrates the issue:
https://github.com/deveth0/spring-boot-config-dash

Do I miss something here or are dashes in profiles currently a problem?
Thanks

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked demo project and reproduce the two configuration-server requests described in the issue, comparing the profile1 and pro-file2 responses. Trace how the server handles profile names in the configuration lookup; done means the dashed profile returns its own configuration instead of the default profile.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring, spring-boot
Domain
backend, cloud
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.