Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-2135

PackagedTextTemplate uses default ResourceStreamLocator first

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 1.4-RC2
    • 1.4-RC3
    • wicket
    • None

    Description

      PackagedTextTemplate:155

      When loading a resource, ResourceStreamLocator should give priority to the application specific locator first, and not using it as a fallback solution if the default ResourceStreamLocator fails to find the resource.

      Imagine an environment where a custom resource locator has been set up to get all the resources from the project source folder (very useful during development to modify markups, css' and js' on the fly through the IDE).
      With the current behavior I have to modify the deployed-version of my resource to make wicket apply the changes on the fly.

      Here's my usual Application.init() method:

      if( Application.DEVELOPMENT.equals( getConfigurationType() ) ){
      getResourceSettings().setResourceStreamLocator(
      new ResourceStreamLocator(
      new Path(
      new Folder(
      getServletContext().getRealPath( "/" ).replaceFirst( "web/", "src/" )
      )
      )
      )
      )
      }

      Attachments

        Activity

          People

            jdonnerstag Juegen Donnerstag
            soulspirit SoulSpirit
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: