def t = groovyPagesTemplateEngine.createTemplate(gsp,"sample")
def out = new StringWriter()
The above code works fine for the first time. But when the gsp value changes the template is created for the initial value of the GSP and not taking the new value. So I need a way to clear the cache and also groovyPagesTemplateEngine.clearPageCache() is not working . Using it in the service and getting the attrs(HashMap) value in taglib which always shows the old value and not the new gsp value.