Grails
  1. Grails
  2. GRAILS-5560

GroovyPagesTemplateEngine does not cache compiled templates for several variants of createTemplate

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2-RC1, 1.2-RC2
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      There are a lot of createTemplate variants on the engine, but very few of them actually attempt to get a page from the cache.

      In particular createTemplate(String content, String pageName) never attempts to cache.

      Surely we can generate a page name for caching purposes that is based on an SHA1 digest of the source template? This may take a little while to compute, but likely a lot less time than compiling the template and leaking permgen? Even then, the digest is only needed if there is no way to tell the engine what the lastmod time is of the template. If there is an extra variant:

      createTemplate(String content, String pageName, Date lastModified)

      ...then this problem can be circumvented also.

        Issue Links

          Activity

          Marc Palmer created issue -
          Graeme Rocher made changes -
          Field Original Value New Value
          Fix Version/s 1.2 final [ 16022 ]
          Fix Version/s 1.2.1 [ 16060 ]
          Graeme Rocher made changes -
          Fix Version/s 1.2.1 [ 16060 ]
          Fix Version/s 1.2.2 [ 16198 ]
          Graeme Rocher made changes -
          Fix Version/s 1.2.3 [ 16313 ]
          Fix Version/s 1.2.2 [ 16198 ]
          Graeme Rocher made changes -
          Assignee Graeme Rocher [ graemerocher ]
          Jeff Scott Brown made changes -
          Fix Version/s 1.2.4 [ 16555 ]
          Fix Version/s 1.2.3 [ 16313 ]
          Jeff Scott Brown made changes -
          Fix Version/s 1.2.4 [ 16555 ]
          Fix Version/s 1.2.5 [ 16652 ]
          Jeff Scott Brown made changes -
          Fix Version/s 1.2.5 [ 16652 ]
          Fix Version/s 1.3.6 [ 16730 ]
          Jeff Scott Brown made changes -
          Fix Version/s 1.3.6 [ 16730 ]
          Fix Version/s 1.4-M1 [ 16812 ]
          Luke Daley made changes -
          Assignee Lari Hotari [ lhotari ]
          Lari Hotari made changes -
          Link This issue relates to GRAILS-3818 [ GRAILS-3818 ]
          Lari Hotari made changes -
          Link This issue relates to GRAILS-6809 [ GRAILS-6809 ]
          Lari Hotari made changes -
          Link This issue is related to GRAILS-7169 [ GRAILS-7169 ]
          Contegix Support made changes -
          Project Import Thu Mar 24 21:22:24 CDT 2011 [ 1301019744151 ]
          Graeme Rocher made changes -
          Fix Version/s 1.4-M2 [ 12504 ]
          Fix Version/s 1.4-M1 [ 11040 ]
          Graeme Rocher made changes -
          Assignee Lari Hotari [ lhotari ] Graeme Rocher [ graemerocher ]
          Graeme Rocher made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0-M2 [ 12805 ]
          Fix Version/s 2.0-M1 [ 12504 ]
          Burt Beckwith made changes -
          Workflow jira [ 33214 ] Grails [ 41590 ]
          Burt Beckwith made changes -
          Workflow Grails [ 41590 ] Copy of Grails [ 49041 ]
          Burt Beckwith made changes -
          Workflow Copy of Grails [ 49041 ] Grails [ 56451 ]
          Graeme Rocher made changes -
          Status In Progress [ 3 ] Open [ 1 ]
          Burt Beckwith made changes -
          Workflow Grails [ 56451 ] Grails2 [ 62824 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0-RC1 [ 12803 ]
          Fix Version/s 2.0-M2 [ 12805 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0.1 [ 13005 ]
          Fix Version/s 2.0-RC1 [ 12803 ]
          Burt Beckwith made changes -
          Workflow Grails2 [ 62824 ] jira [ 71181 ]
          Burt Beckwith made changes -
          Workflow jira [ 71181 ] Grails2 [ 79224 ]
          Peter Ledbrook made changes -
          Last Reviewed 01/Jan/10
          Peter Ledbrook made changes -
          Workflow Grails2 [ 79224 ] jira [ 88036 ]
          Peter Ledbrook made changes -
          Workflow jira [ 88036 ] Grails2 [ 96248 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0.2 [ 13064 ]
          Fix Version/s 2.0.1 [ 13005 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0.3 [ 13094 ]
          Fix Version/s 2.0.2 [ 13064 ]
          Graeme Rocher made changes -
          Fix Version/s 2.0.4 [ 13099 ]
          Fix Version/s 2.0.3 [ 13094 ]
          Jeff Scott Brown made changes -
          Fix Version/s 2.2 [ 13093 ]
          Fix Version/s 2.0.4 [ 13099 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3 [ 13311 ]
          Fix Version/s 2.2-RC1 [ 13093 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3-M2 [ 13457 ]
          Fix Version/s 2.3-M1 [ 13311 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3-RC1 [ 13458 ]
          Fix Version/s 2.3-M2 [ 13457 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3-RC2 [ 13482 ]
          Fix Version/s 2.3-RC1 [ 13458 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3.1 [ 13502 ]
          Fix Version/s 2.3-RC2 [ 13482 ]
          Graeme Rocher made changes -
          Fix Version/s 2.3.1 [ 13502 ]

            People

            • Assignee:
              Graeme Rocher
              Reporter:
              Marc Palmer
            • Votes:
              3 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Last Reviewed:

                Development