org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null

Atlassian JIRA | Sudhakar Ramasamy | 1 decade ago
  1. 0

    We noticed that our confluence failed to come up that the application had crashed. Here's what we had in the log files: 2006-11-03 10:44:51,416 ERROR [opensymphony.webwork.dispatcher.VelocityResult] doExecute Unable to render Velocity Template, '/users/viewuserprofile.vm' org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:188) at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:226) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:207) .................... at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) caused by: java.lang.NullPointerException at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getPersonalSpaceKey(AbstractUserProfileAction.java:425) at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getSpace(AbstractUserProfileAction.java:420) at sun.reflect.GeneratedMethodAccessor2403.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) ........................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,428 ERROR [opensymphony.webwork.dispatcher.ServletDispatcher] serviceAction Could not execute action org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:188) at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:226) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:207) at org.apache.velocity.runtime.parser.node.ASTReference.evaluate(ASTReference.java:337) at org.apache.velocity.runtime.parser.node.ASTNotNode.evaluate(ASTNotNode.java:85) ................................. at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) caused by: java.lang.NullPointerException at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getPersonalSpaceKey(AbstractUserProfileAction.java:425) at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getSpace(AbstractUserProfileAction.java:420) at sun.reflect.GeneratedMethodAccessor2403.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:154) ..................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,434 ERROR [[Catalina].[localhost].[/wiki].[action]] invoke Servlet.service() for servlet action threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ......................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,438 WARN [confluence.servlet.simpledisplay.SimpleDisplayServlet] doGet Error while parsing path /~Unknown java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,442 ERROR [[Catalina].[localhost].[/wiki].[simple-display]] invoke Servlet.service() for servlet simple-display threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ..................................... at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595)

    Atlassian JIRA | 1 decade ago | Sudhakar Ramasamy
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null
  2. 0

    We noticed that our confluence failed to come up that the application had crashed. Here's what we had in the log files: 2006-11-03 10:44:51,416 ERROR [opensymphony.webwork.dispatcher.VelocityResult] doExecute Unable to render Velocity Template, '/users/viewuserprofile.vm' org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:188) at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:226) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:207) .................... at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) caused by: java.lang.NullPointerException at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getPersonalSpaceKey(AbstractUserProfileAction.java:425) at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getSpace(AbstractUserProfileAction.java:420) at sun.reflect.GeneratedMethodAccessor2403.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) ........................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,428 ERROR [opensymphony.webwork.dispatcher.ServletDispatcher] serviceAction Could not execute action org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:188) at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:226) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:207) at org.apache.velocity.runtime.parser.node.ASTReference.evaluate(ASTReference.java:337) at org.apache.velocity.runtime.parser.node.ASTNotNode.evaluate(ASTNotNode.java:85) ................................. at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) caused by: java.lang.NullPointerException at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getPersonalSpaceKey(AbstractUserProfileAction.java:425) at com.atlassian.confluence.user.actions.AbstractUserProfileAction.getSpace(AbstractUserProfileAction.java:420) at sun.reflect.GeneratedMethodAccessor2403.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:154) ..................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,434 ERROR [[Catalina].[localhost].[/wiki].[action]] invoke Servlet.service() for servlet action threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ......................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,438 WARN [confluence.servlet.simpledisplay.SimpleDisplayServlet] doGet Error while parsing path /~Unknown java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ................................... at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) 2006-11-03 10:44:51,442 ERROR [[Catalina].[localhost].[/wiki].[simple-display]] invoke Servlet.service() for servlet simple-display threw exception java.lang.IllegalStateException at org.apache.catalina.connector.ResponseFacade.sendError(ResponseFacade.java:404) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) at javax.servlet.http.HttpServletResponseWrapper.sendError(HttpServletResponseWrapper.java:107) ..................................... at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595)

    Atlassian JIRA | 1 decade ago | Sudhakar Ramasamy
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null
  3. 0

    Getting error Failed to generate HTML Report by use of ReportNG with Maven.

    Google Groups | 4 years ago | Omkar Khatavkar
    org.uncommons.reportng.ReportNGException: Failed generating HTML report.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    h2. Problem description This error occurs for new installations of 4.0.3 where, in the setup wizard, the user has opted to install the demo space. And under certain circumstances which the error is caused by a malformed row in the table *bodycontent*. *However it is not fixed on upgrade, the error remains.* Here are the steps that you can take to reproduce this bug : # Install a clean instance of Confluence 4.0.3. (Installed by following the setup wizard, and set user management to 'Manage Users and Groups within Confluence') # Access {{Browse>Space Directory}} and there will be an error. The stack trace is as follows : {code} org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getBodyAsString' in class com.atlassian.confluence.spaces.SpaceDescription$$EnhancerByCGLIB$$f653be5e threw exception java.lang.UnsupportedOperationException: The body of this ContentEntityObject ('') was 'BodyType:XHTML' but was expected to be 'BodyType:WIKI' at /templates/spacedirectory.vm[line 62, column 71] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:284) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:262) ... Caused by: java.lang.UnsupportedOperationException: The body of this ContentEntityObject ('') was 'BodyType:XHTML' but was expected to be 'BodyType:WIKI' at com.atlassian.confluence.core.ContentEntityObject.getBodyContent(ContentEntityObject.java:169) at com.atlassian.confluence.core.ContentEntityObject.getBodyAsString(ContentEntityObject.java:206) at com.atlassian.confluence.core.ContentEntityObject$$FastClassByCGLIB$$96df24d5.invoke(<generated>) at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149) at net.sf.hibernate.proxy.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:108) at com.atlassian.confluence.spaces.SpaceDescription$$EnhancerByCGLIB$$f653be5e.getBodyAsString(<generated>) ... 197 more {code} h2.Workaround # Open this URL in your browser: <Confluence-URL>/admin/force-upgrade.action # Select *changeSpaceDescriptionsBodyTypeUpgradeTask* in the Upgrade task to run dropdown list. # Choose Force Upgrade. Hope This helps!

    Atlassian JIRA | 5 years ago | Carlos Alberto Feijo Schedler [Atlassian]
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getBodyAsString' in class com.atlassian.confluence.spaces.SpaceDescription$$EnhancerByCGLIB$$f653be5e threw exception java.lang.UnsupportedOperationException: The body of this ContentEntityObject ('') was 'BodyType:XHTML' but was expected to be 'BodyType:WIKI' at /templates/spacedirectory.vm[line 62, column 71]
  6. 0

    I've noticed the following exception in a watchlist email in XEM mode: {noformat} Error number 4001 in 4: Error while parsing velocity page xwiki:XWiki.WatchListMessage Wrapped Exception: Failed to evaluate content with id [xwiki:XWiki.WatchListMessage] com.xpn.xwiki.XWikiException: Error number 4001 in 4: Error while parsing velocity page xwiki:XWiki.WatchListMessage Wrapped Exception: Failed to evaluate content with id [xwiki:XWiki.WatchListMessage] at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:122) at com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMailFromTemplate(MailSenderPlugin.java:806) at com.xpn.xwiki.plugin.watchlist.WatchListNotifier.sendEmailNotification(WatchListNotifier.java:133) at com.xpn.xwiki.plugin.watchlist.WatchListJob.executeJob(WatchListJob.java:262) at com.xpn.xwiki.plugin.scheduler.AbstractJob.execute(AbstractJob.java:75) at org.quartz.core.JobRunShell.run(JobRunShell.java:202) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525) Wrapped Exception: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDocument' in class com.xpn.xwiki.api.XWiki threw exception java.lang.NullPointerException at xwiki:XWiki.WatchListMessage[line 74, column 31] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:284) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:252) {noformat}

    XWiki.org JIRA | 7 years ago | Ludovic Dubost
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getDocument' in class com.xpn.xwiki.api.XWiki threw exception java.lang.NullPointerException at xwiki:XWiki.WatchListMessage[line 74, column 31]

    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 'getSpace' in class com.atlassian.confluence.user.actions.ViewUserProfileAction threw exception class java.lang.NullPointerException : null

      at org.apache.velocity.runtime.parser.node.PropertyExecutor.execute()
    2. Apache Velocity
      ASTReference.execute
      1. org.apache.velocity.runtime.parser.node.PropertyExecutor.execute(PropertyExecutor.java:188)
      2. org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:226)
      3. org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:207)
      3 frames