spring-projects / spring-projects/spring-boot

Update ConfigDataEnvironmentContributors to allow imports to access previous contributions

Open
#28,849 6 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type: enhancement
Dominant language
Java
Stars
81.5k
Forks
42.7k
Avg merge
2d 4h
Merged PRs (30d)
65

Description

See https://github.com/spring-cloud/spring-cloud-vault/issues/607#issuecomment-977666573 for more background.

Currently ConfigDataLocationResolverContext.getBinder() is documented as "Provides access to a binder that can be used to obtain previously contributed values", but the actual binder here only provides access to parent contributions. This is because ConfigDataEnvironmentContributors.withProcessedImports processes all imports in a single hit, rather than doing them one at a time and creating a new ConfigDataLoaderContext.

If we change this logic then a ConfigDataLocationResolver should be able to make use of previously contributed data.

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 ConfigDataEnvironmentContributors.withProcessedImports and trace how ConfigDataLocationResolverContext.getBinder() and ConfigDataLoaderContext are created while imports are processed. Compare the documented access to previously contributed values with the current parent-only behavior. Done means a resolver can access contributions from earlier imports, with regression coverage added in the relevant configuration-data tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring-boot
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 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.