Uploaded image for project: 'Spring Framework'
  1. Spring Framework
  2. SPR-10686

${} placeholders are not resolved in @ImportResource

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.2.3
    • Fix Version/s: 3.2.4, 4.0 M2
    • Component/s: None
    • Labels:
      None
    • Last commented by a User:
      true

      Description

      ${} placeholders are not substituted with values from Environment's PropertySources.

      This can be easily fixed by changing line 216 of org.springframework.context.annotation.ConfigurationClassParser

      from:

      configClass.addImportedResource(resource, readerClass);
      

      to:

      configClass.addImportedResource(environment.resolveRequiredPlaceholders(resource), readerClass);
      

      Would very much appreciate it if the fix was included into the upcoming 3.2.4 release.

        Attachments

          Activity

            People

            • Assignee:
              pwebb Phil Webb
              Reporter:
              akolyagin Alexey Kolyagin
              Last updater:
              Spring Issuemaster
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                26 weeks, 4 days ago