org.apache.velocity.exception.MethodInvocationException: Invocation of method 'copyDocument' in class com.xpn.xwiki.api.XWiki threw exception com.xpn.xwiki.XWikiException: Error number 3301 in 3: Exception while switching to database xwiki Wrapped Exception: null at /templates/copy.vm[line 51, column 18]

XWiki.org JIRA | Elena-Oana Tabaranu | 4 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Steps to reproduce: * Go on the XWiki.ClassSheet page of your wiki. * Select the copy option from the menu Page: ClassSheet > Copy * Fill in the target space and click the "Copy" button Result: the page is not copied and a velocity errors are displayed {code} Wrapped Exception: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'copyDocument' in class com.xpn.xwiki.api.XWiki threw exception com.xpn.xwiki.XWikiException: Error number 3301 in 3: Exception while switching to database xwiki Wrapped Exception: null at /templates/copy.vm[line 51, column 18] at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:243) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:187) ... Caused by: com.xpn.xwiki.XWikiException: Error number 3301 in 3: Exception while switching to database xwiki Wrapped Exception: null at com.xpn.xwiki.store.XWikiHibernateBaseStore.setDatabase(XWikiHibernateBaseStore.java:661) at com.xpn.xwiki.store.XWikiHibernateBaseStore.beginTransaction(XWikiHibernateBaseStore.java:832) at com.xpn.xwiki.store.XWikiHibernateBaseStore.beginTransaction(XWikiHibernateBaseStore.java:732) at com.xpn.xwiki.store.XWikiHibernateBaseStore.execute(XWikiHibernateBaseStore.java:1220) at com.xpn.xwiki.store.XWikiHibernateBaseStore.executeWrite(XWikiHibernateBaseStore.java:1307) at com.xpn.xwiki.store.XWikiHibernateVersioningStore.saveXWikiDocArchive(XWikiHibernateVersioningStore.java:175) at com.xpn.xwiki.XWiki.copyDocument(XWiki.java:4062) at com.xpn.xwiki.api.XWiki.copyDocument(XWiki.java:1491) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:395) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:384) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:173) ... 57 more Caused by: java.lang.NullPointerException at com.xpn.xwiki.store.migration.AbstractDataMigrationManager.getXWikiContext(AbstractDataMigrationManager.java:284) at com.xpn.xwiki.store.migration.AbstractDataMigrationManager.getDataMigrationStatus(AbstractDataMigrationManager.java:406) at com.xpn.xwiki.store.migration.AbstractDataMigrationManager.checkDatabase(AbstractDataMigrationManager.java:520) at com.xpn.xwiki.store.XWikiHibernateBaseStore.setDatabase(XWikiHibernateBaseStore.java:657) {code}

    XWiki.org JIRA | 4 years ago | Elena-Oana Tabaranu
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'copyDocument' in class com.xpn.xwiki.api.XWiki threw exception com.xpn.xwiki.XWikiException: Error number 3301 in 3: Exception while switching to database xwiki Wrapped Exception: null at /templates/copy.vm[line 51, column 18]
  2. 0

    Test Table Coloring Should Not Instantiate Fixtures

    GitHub | 2 years ago | mwarhaftig
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'render' in class fitnesse.responders.WikiPageResponder$WikiTestPageRenderer threw exception java.lang.NullPointerException at wikiPage.vm[line 1, column 10]
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    Cause: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'isEmpty' in class com.atlassian.user.search.page.MergedPager threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:309) caused by: java.lang.NullPointerException at com.atlassian.user.search.page.MergedPager.isEmpty(MergedPager.java:24) Stack Trace: [hide] org.apache.velocity.exception.MethodInvocationException: Invocation of method 'isEmpty' in class com.atlassian.user.search.page.MergedPager threw exception class java.lang.NullPointerException : null at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:309) 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.ASTExpression.evaluate(ASTExpression.java:84) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:271) at org.apache.velocity.Template.merge(Template.java:296) at com.opensymphony.webwork.dispatcher.VelocityResult.doExecute(VelocityResult.java:91) at bucket.util.profiling.ProfiledVelocityResult.doExecute(ProfiledVelocityResult.java:18) 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.security.actions.PermissionCheckInterceptor.intercept(PermissionCheckInterceptor.java:39) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165) at com.atlassian.confluence.pages.actions.PageAwareInterceptor.intercept(PageAwareInterceptor.java:94)

    Atlassian JIRA | 1 decade ago | Dave Loeng [Atlassian]
    org.apache.velocity.exception.MethodInvocationException: Invocation of method 'isEmpty' in class com.atlassian.user.search.page.MergedPager threw exception class java.lang.NullPointerException : null

    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 'copyDocument' in class com.xpn.xwiki.api.XWiki threw exception com.xpn.xwiki.XWikiException: Error number 3301 in 3: Exception while switching to database xwiki Wrapped Exception: null at /templates/copy.vm[line 51, column 18]

      at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException()
    2. Apache Velocity
      ASTMethod.execute
      1. org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:243)
      2. org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:187)
      2 frames