Spring Framework
  1. Spring Framework
  2. SPR-5106

Make script source locator mechanism pluggable

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.5.5
    • Fix Version/s: General Backlog
    • Component/s: Core
    • Labels:
      None
    • Last commented by a User:
      true

      Description

      Currently ScriptFactoryPostProcessor's convertToScriptSource method allows only inline or Resource-based scripts. Suggest that ScriptFactoryPostProcessor should allow the script locator mechanism to be pluggable and allow scripts to be loaded from anywhere.

      Something along the lines of extracting the convertToScriptSource() method in ScriptFactoryPostProcessor into a pluggable strategy, with perhaps a default if you don't want to do anything more than inline or Resource-based scripts. So maybe there would be a ScriptLocator interface which you could plug into the ScriptFactoryPostProcessor rather than needing to subclass SFPP and override the protected convertToScriptSource method, which I did to allow scripts to be loaded from a database.

        Activity

          People

          • Assignee:
            Juergen Hoeller
            Reporter:
            Scott Leberknight
            Last updater:
            Trevor Marshall
          • Votes:
            5 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:
              Days since last comment:
              5 years, 36 weeks ago