org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45]

Atlassian JIRA | Harold Murn | 1 year ago
  1. 0

    h3. Summary A page with the "Content by label" macro, combined with an Excerpt Display of "Rich content", will render itself leading to a stack overflow. *This causes:* * high CPU usage with more than 10MB of log every second. * Confluence becomes unresponsive until the overflow finishes. * Going to the page can also return an Error page when the page is displayed. * The page may render with infinite traces of itself. * In Cloud the page will automatically try to refresh every 2 minutes if window is left open and will trigger the problem again. h3. Environment * Confluence 6.0 * Content by Label macro h3. Steps to Reproduce # Create a new page # Add a "Content by label" macro, configured as: #* Label: "testing" #* Excerpt Display: "rich content" # Save the page # Add a label to the page: "testing" # Refresh the page (May require 2 or 3 refreshes for the label to be updated) h3. Expected Results Page renders quickly and no error are shown in the logs. h3. Actual Results Log shows many errors: {noformat} 2016-01-08 13:19:53.758403500 2016-01-08 13:19:53,749 ERROR [http-bio-1990-exec-4] [xhtml.view.macro.ViewMacroMarshaller] marshalInternal Error rendering macro: contentbylabel 2016-01-08 13:19:53.758404500 -- url: /wiki/display/TES/KB0001 | page: 3735562 | traceId: 8aa2ccdd327d6df3 | userName: usertest | referer: https://<url>/wiki/pages/editpage.action?pageId=3735562 | action: viewpage 2016-01-08 13:19:53.758405500 java.lang.StackOverflowError 2016-01-08 13:19:53.758405500 at org.antlr.v4.runtime.misc.Array2DHashSet.getOrAdd(Array2DHashSet.java:83) 2016-01-08 13:19:53.758437500 at org.antlr.v4.runtime.atn.ATNConfigSet.add(ATNConfigSet.java:167) 2016-01-08 13:19:53.758437500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1447) 2016-01-08 13:19:53.758438500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758438500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758446500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758447500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758447500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758452500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758452500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758453500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758453500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758456500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758460500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758461500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758461500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758466500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758469500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758469500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758470500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758470500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758473500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758473500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758479500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758479500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758480500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758480500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758483500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758489500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758490500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758490500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758494500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758494500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758495500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758495500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758498500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758498500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758499500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758499500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758502500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758503500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758506500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758507500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758507500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758508500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758510500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure(ParserATNSimulator.java:1370) 2016-01-08 13:19:53.758511500 at org.antlr.v4.runtime.atn.ParserATNSimulator.computeReachSet(ParserATNSimulator.java:884) 2016-01-08 13:19:53.758511500 at org.antlr.v4.runtime.atn.ParserATNSimulator.execATNWithFullContext(ParserATNSimulator.java:695) 2016-01-08 13:19:53.758512500 at org.antlr.v4.runtime.atn.ParserATNSimulator.execATN(ParserATNSimulator.java:534) 2016-01-08 13:19:53.758514500 at org.antlr.v4.runtime.atn.ParserATNSimulator.adaptivePredict(ParserATNSimulator.java:423) 2016-01-08 13:19:53.758515500 at com.atlassian.querylang.antlrgen.AqlParser.expr(AqlParser.java:1228) 2016-01-08 13:19:53.758515500 at com.atlassian.querylang.antlrgen.AqlParser.subClause(AqlParser.java:1114) 2016-01-08 13:19:53.758531500 at com.atlassian.querylang.antlrgen.AqlParser.andClause(AqlParser.java:983) 2016-01-08 13:19:53.758531500 at com.atlassian.querylang.antlrgen.AqlParser.orClause(AqlParser.java:915) 2016-01-08 13:19:53.758532500 at com.atlassian.querylang.antlrgen.AqlParser.clause(AqlParser.java:864) 2016-01-08 13:19:53.758532500 at com.atlassian.querylang.antlrgen.AqlParser.aqlStatement(AqlParser.java:624) 2016-01-08 13:19:53.758535500 at com.atlassian.querylang.lib.parserfactory.DefaultParserFactory.createParser(DefaultParserFactory.java:36) 2016-01-08 13:19:53.758535500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.createParserForInput(DefaultCQLSearchService.java:339) 2016-01-08 13:19:53.758536500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.performV2Search(DefaultCQLSearchService.java:240) 2016-01-08 13:19:53.758538500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.searchContent(DefaultCQLSearchService.java:175) 2016-01-08 13:19:53.758539500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.searchContent(DefaultCQLSearchService.java:122) 2016-01-08 13:19:53.758539500 at com.atlassian.confluence.plugins.macros.advanced.contentbylabel.LabelledContentMacro.makeRenderContext(LabelledContentMacro.java:109) 2016-01-08 13:19:53.758546500 at com.atlassian.confluence.plugins.macros.advanced.contentbylabel.LabelledContentMacro.execute(LabelledContentMacro.java:85) 2016-01-08 13:19:53.758547500 at com.atlassian.confluence.macro.ContentFilteringMacro.execute(ContentFilteringMacro.java:107) 2016-01-08 13:19:53.758547500 at com.atlassian.renderer.v2.macro.ResourceAwareMacroDecorator.execute(ResourceAwareMacroDecorator.java:51) 2016-01-08 13:19:53.758550500 at com.atlassian.confluence.macro.V2CompatibilityMacro.execute(V2CompatibilityMacro.java:41) 2016-01-08 13:19:53.758550500 at com.atlassian.confluence.macro.LazyLoadingMacroWrapper.execute(LazyLoadingMacroWrapper.java:27) truncated to fit comment {noformat} On Screen it may show the error: "Oops - an error has occurred" with the following error: {noformat} Cause java.lang.RuntimeException: Error rendering template for decorator root at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) caused by: java.lang.RuntimeException: Error rendering template for decorator page at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) caused by: net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at net.sf.hibernate.collection.PersistentCollection.initialize(PersistentCollection.java:201) caused by: net.sf.hibernate.HibernateException: collection was evicted at net.sf.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:3332) Stack Trace:[hide] java.lang.RuntimeException: Error rendering template for decorator root at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.apache.velocity.Template.merge(Template.java:328) at org.apache.velocity.Template.merge(Template.java:235) at com.opensymphony.webwork.dispatcher.VelocityResult.doExecute(VelocityResult.java:91) at com.atlassian.xwork.results.ProfiledVelocityResult.doExecute(ProfiledVelocityResult.java:21) at com.atlassian.confluence.setup.webwork.EncodingVelocityResult.doExecute(EncodingVelocityResult.java:48) at com.opensymphony.webwork.dispatcher.WebWorkResultSupport.execute(WebWorkResultSupport.java:116) at com.opensymphony.xwork.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:263) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:187) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:65) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) truncated to fit. {noformat} h3. Notes Wasn't happening in Confluence v5.7 and v5.8.10 because the macro didn't have the 'Rich Content' excerpt. This is the Macro setting: !rich_content_setting.jpeg|thumbnail! h3.Workaround User a different 'Excerpt Display' option in the macro. To open the page directly in edit mode: # get the contentid from the database (Cloud customers please contact Cloud Support) {noformat} select * from content where title like 'Title of the page' and content_status = 'current' and spaceid > 0; {noformat} # use the 'contentid' as the page id value in: {{https://<confluence-url>/pages/editpage.action?pageId=}}

    Atlassian JIRA | 1 year ago | Harold Murn
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45]
  2. 0

    h3. Summary A page with the "Content by label" macro, combined with an Excerpt Display of "Rich content", will render itself leading to a stack overflow. *This causes:* * high CPU usage with more than 10MB of log every second. * Confluence becomes unresponsive until the overflow finishes. * Going to the page can also return an Error page when the page is displayed. * The page may render with infinite traces of itself. * In Cloud the page will automatically try to refresh every 2 minutes if window is left open and will trigger the problem again. h3. Environment * Confluence 6.0 * Content by Label macro h3. Steps to Reproduce # Create a new page # Add a "Content by label" macro, configured as: #* Label: "testing" #* Excerpt Display: "rich content" # Save the page # Add a label to the page: "testing" # Refresh the page (May require 2 or 3 refreshes for the label to be updated) h3. Expected Results Page renders quickly and no error are shown in the logs. h3. Actual Results Log shows many errors: {noformat} 2016-01-08 13:19:53.758403500 2016-01-08 13:19:53,749 ERROR [http-bio-1990-exec-4] [xhtml.view.macro.ViewMacroMarshaller] marshalInternal Error rendering macro: contentbylabel 2016-01-08 13:19:53.758404500 -- url: /wiki/display/TES/KB0001 | page: 3735562 | traceId: 8aa2ccdd327d6df3 | userName: usertest | referer: https://<url>/wiki/pages/editpage.action?pageId=3735562 | action: viewpage 2016-01-08 13:19:53.758405500 java.lang.StackOverflowError 2016-01-08 13:19:53.758405500 at org.antlr.v4.runtime.misc.Array2DHashSet.getOrAdd(Array2DHashSet.java:83) 2016-01-08 13:19:53.758437500 at org.antlr.v4.runtime.atn.ATNConfigSet.add(ATNConfigSet.java:167) 2016-01-08 13:19:53.758437500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1447) 2016-01-08 13:19:53.758438500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758438500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758446500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758447500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758447500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758452500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758452500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758453500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758453500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758456500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758457500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758460500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758461500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758461500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758465500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758466500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758469500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758469500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758470500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758470500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758473500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758473500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758479500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758479500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758480500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758480500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758483500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758484500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758489500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758490500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758490500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758494500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758494500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758495500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758495500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758498500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758498500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758499500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758499500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758502500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758503500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758506500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758507500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1414) 2016-01-08 13:19:53.758507500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure_(ParserATNSimulator.java:1492) 2016-01-08 13:19:53.758508500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closureCheckingStopState(ParserATNSimulator.java:1431) 2016-01-08 13:19:53.758510500 at org.antlr.v4.runtime.atn.ParserATNSimulator.closure(ParserATNSimulator.java:1370) 2016-01-08 13:19:53.758511500 at org.antlr.v4.runtime.atn.ParserATNSimulator.computeReachSet(ParserATNSimulator.java:884) 2016-01-08 13:19:53.758511500 at org.antlr.v4.runtime.atn.ParserATNSimulator.execATNWithFullContext(ParserATNSimulator.java:695) 2016-01-08 13:19:53.758512500 at org.antlr.v4.runtime.atn.ParserATNSimulator.execATN(ParserATNSimulator.java:534) 2016-01-08 13:19:53.758514500 at org.antlr.v4.runtime.atn.ParserATNSimulator.adaptivePredict(ParserATNSimulator.java:423) 2016-01-08 13:19:53.758515500 at com.atlassian.querylang.antlrgen.AqlParser.expr(AqlParser.java:1228) 2016-01-08 13:19:53.758515500 at com.atlassian.querylang.antlrgen.AqlParser.subClause(AqlParser.java:1114) 2016-01-08 13:19:53.758531500 at com.atlassian.querylang.antlrgen.AqlParser.andClause(AqlParser.java:983) 2016-01-08 13:19:53.758531500 at com.atlassian.querylang.antlrgen.AqlParser.orClause(AqlParser.java:915) 2016-01-08 13:19:53.758532500 at com.atlassian.querylang.antlrgen.AqlParser.clause(AqlParser.java:864) 2016-01-08 13:19:53.758532500 at com.atlassian.querylang.antlrgen.AqlParser.aqlStatement(AqlParser.java:624) 2016-01-08 13:19:53.758535500 at com.atlassian.querylang.lib.parserfactory.DefaultParserFactory.createParser(DefaultParserFactory.java:36) 2016-01-08 13:19:53.758535500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.createParserForInput(DefaultCQLSearchService.java:339) 2016-01-08 13:19:53.758536500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.performV2Search(DefaultCQLSearchService.java:240) 2016-01-08 13:19:53.758538500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.searchContent(DefaultCQLSearchService.java:175) 2016-01-08 13:19:53.758539500 at com.atlassian.confluence.plugins.cql.impl.DefaultCQLSearchService.searchContent(DefaultCQLSearchService.java:122) 2016-01-08 13:19:53.758539500 at com.atlassian.confluence.plugins.macros.advanced.contentbylabel.LabelledContentMacro.makeRenderContext(LabelledContentMacro.java:109) 2016-01-08 13:19:53.758546500 at com.atlassian.confluence.plugins.macros.advanced.contentbylabel.LabelledContentMacro.execute(LabelledContentMacro.java:85) 2016-01-08 13:19:53.758547500 at com.atlassian.confluence.macro.ContentFilteringMacro.execute(ContentFilteringMacro.java:107) 2016-01-08 13:19:53.758547500 at com.atlassian.renderer.v2.macro.ResourceAwareMacroDecorator.execute(ResourceAwareMacroDecorator.java:51) 2016-01-08 13:19:53.758550500 at com.atlassian.confluence.macro.V2CompatibilityMacro.execute(V2CompatibilityMacro.java:41) 2016-01-08 13:19:53.758550500 at com.atlassian.confluence.macro.LazyLoadingMacroWrapper.execute(LazyLoadingMacroWrapper.java:27) truncated to fit comment {noformat} On Screen it may show the error: "Oops - an error has occurred" with the following error: {noformat} Cause java.lang.RuntimeException: Error rendering template for decorator root at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) caused by: java.lang.RuntimeException: Error rendering template for decorator page at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) caused by: net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at net.sf.hibernate.collection.PersistentCollection.initialize(PersistentCollection.java:201) caused by: net.sf.hibernate.HibernateException: collection was evicted at net.sf.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:3332) Stack Trace:[hide] java.lang.RuntimeException: Error rendering template for decorator root at com.atlassian.confluence.setup.velocity.ApplyDecoratorDirective.render(ApplyDecoratorDirective.java:183) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:175) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336) at org.apache.velocity.Template.merge(Template.java:328) at org.apache.velocity.Template.merge(Template.java:235) at com.opensymphony.webwork.dispatcher.VelocityResult.doExecute(VelocityResult.java:91) at com.atlassian.xwork.results.ProfiledVelocityResult.doExecute(ProfiledVelocityResult.java:21) at com.atlassian.confluence.setup.webwork.EncodingVelocityResult.doExecute(EncodingVelocityResult.java:48) at com.opensymphony.webwork.dispatcher.WebWorkResultSupport.execute(WebWorkResultSupport.java:116) at com.opensymphony.xwork.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:263) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:187) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:65) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35) truncated to fit. {noformat} h3. Notes Wasn't happening in Confluence v5.7 and v5.8.10 because the macro didn't have the 'Rich Content' excerpt. This is the Macro setting: !rich_content_setting.jpeg|thumbnail! h3.Workaround User a different 'Excerpt Display' option in the macro. To open the page directly in edit mode: # get the contentid from the database (Cloud customers please contact Cloud Support) {noformat} select * from content where title like 'Title of the page' and content_status = 'current' and spaceid > 0; {noformat} # use the 'contentid' as the page id value in: {{https://<confluence-url>/pages/editpage.action?pageId=}}

    Atlassian JIRA | 1 year ago | Harold Murn
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45]
  3. 0

    Chat history - A system error has occurred

    GitHub | 3 years ago | sniadek
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'canView' in class com.atlassian.confluence.security.PermissionHelper threw exception java.lang.IllegalArgumentException: Could not check permissions for michals no suitable delegate found. at template/includes/macros.vm[line 1308, column 39]
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    [CONF-38084] Error when visiting pages with JIRA integrations, caused by duplicate AppLinks keys - Atlassian JIRA

    atlassian.com | 1 year ago
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 125, column 45]
  6. 0

    h5. Steps to Reproduce # Change system locale to Turkish # Go to {{Dashboard -> Administration -> View Global Permissions}} # Edit Permissions You will get a System Error page with something like this {code} org.apache.velocity.exception.MethodInvocationException: Invocation of method 'canSetPermissionOnGroup' in class com.atlassian.confluence.security.actions.EditGlobalPermissionsAction threw exception java.lang.IllegalArgumentException: Unknown global permission: profileattachments at /admin/permissions/editglobalperms.vm[line 53, column 52] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) caused by: java.lang.IllegalArgumentException: Unknown global permission: profileattachments at com.atlassian.confluence.security.administrators.EditGlobalPermissionsAdministrator.canSetPermissionOnGroup(EditGlobalPermissionsAdministrator.java:100) {code} \\ h5. Findings || Confluence Version || Remark || | 3.1, 3.1.1, 3.1.2, 3.2 | Tested and affected | | 2.10.4, 3.0.0_01, 3.0.1, 3.0.2 | Unable to test due to [CONF-17160] | \\ h5. Workaround Cited from [CONF-7168|http://jira.atlassian.com/browse/CONF-7168?focusedCommentId=67700&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#action_67700] {quote} As a work-around, please pass these arguments to your JVM by adding them to JAVA_OPTS in setenv.bat: -Duser.country=EN -Duser.language=en {quote}

    Atlassian JIRA | 7 years ago | Husein Alatas [Atlassian]
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'canSetPermissionOnGroup' in class com.atlassian.confluence.security.actions.EditGlobalPermissionsAction threw exception java.lang.IllegalArgumentException: Unknown global permission: profileattachments at /admin/permissions/editglobalperms.vm[line 53, column 52]

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.apache.velocity.exception.MethodInvocationException

      Invocation of method 'getDisplayableItems' in class com.atlassian.confluence.plugin.descriptor.web.ConfluenceWebInterfaceManager threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 150, column 45]

      at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException()
    2. Apache Velocity
      ASTMethod.handleInvocationException
      1. org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337)
      1 frame