java.lang.reflect.InvocationTargetException

Terracotta Project Issue Tracker | Andrei Costescu | 5 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    When testing compatibility with 3.6.0: I have roots defined in tc-config.xml just like this (of course with my annotation class instead of the one below taken from config reference file): Code: <roots> <root> <field-expression>@com.example.MyRootAnnotation * *</field-expression> </root> </roots> Running the terracotta client fails with exception: Code: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.createGlobalContext(ClassProcessorHelper.java:473) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.initialize(ClassProcessorHelper.java:347) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.defineClass0Pre(ClassProcessorHelper.java:512) at java.lang.ClassLoader.defineClassCond(Unknown Source) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$000(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.__tc_loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) Caused by: java.lang.NullPointerException: string is null at com.tc.util.Assert.assertNotNull(Assert.java:149) at com.tc.util.Assert.assertNotEmpty(Assert.java:195) at com.tc.util.Assert.assertNotBlank(Assert.java:216) at com.tc.util.Assert.assertNotBlank(Assert.java:227) at com.tc.object.config.schema.Root.<init>(Root.java:18) at com.tc.object.config.schema.DSOApplicationConfigObject.translateRoots(DSOApplicationConfigObject.java:108) at com.tc.object.config.schema.DSOApplicationConfigObject.<init>(DSOApplicationConfigObject.java:50) at com.tc.config.schema.setup.BaseConfigurationSetupManager.createNewDSOApplicationConfig(BaseConfigurationSetupManager.java:155) at com.tc.config.schema.setup.BaseConfigurationSetupManager.dsoApplicationConfigFor(BaseConfigurationSetupManager.java:147) at com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:224) at com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:182) at com.tc.object.bytecode.hook.impl.DSOContextImpl.getGlobalConfigHelper(DSOContextImpl.java:322) at com.tc.object.bytecode.hook.impl.DSOContextImpl.createGlobalContext(DSOContextImpl.java:98) ... 20 more From what I can find in the docs/schema this should still work as expected. Last time I tested with 3.4.0 it worked... I need this as some roots can be obfuscated... so listing them 1 by 1 using <field-name> is not an option right now. From what I can tell from looking into terracotta code, <field-name> MUST be used which is wrong if you look at docs/schema. Please make <field-expression> work again.

    Terracotta Project Issue Tracker | 5 years ago | Andrei Costescu
    java.lang.reflect.InvocationTargetException
  2. 0

    When testing compatibility with 3.6.0: I have roots defined in tc-config.xml just like this (of course with my annotation class instead of the one below taken from config reference file): Code: <roots> <root> <field-expression>@com.example.MyRootAnnotation * *</field-expression> </root> </roots> Running the terracotta client fails with exception: Code: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.createGlobalContext(ClassProcessorHelper.java:473) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.initialize(ClassProcessorHelper.java:347) at com.tc.object.bytecode.hook.impl.ClassProcessorHelper.defineClass0Pre(ClassProcessorHelper.java:512) at java.lang.ClassLoader.defineClassCond(Unknown Source) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$000(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.__tc_loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) Caused by: java.lang.NullPointerException: string is null at com.tc.util.Assert.assertNotNull(Assert.java:149) at com.tc.util.Assert.assertNotEmpty(Assert.java:195) at com.tc.util.Assert.assertNotBlank(Assert.java:216) at com.tc.util.Assert.assertNotBlank(Assert.java:227) at com.tc.object.config.schema.Root.<init>(Root.java:18) at com.tc.object.config.schema.DSOApplicationConfigObject.translateRoots(DSOApplicationConfigObject.java:108) at com.tc.object.config.schema.DSOApplicationConfigObject.<init>(DSOApplicationConfigObject.java:50) at com.tc.config.schema.setup.BaseConfigurationSetupManager.createNewDSOApplicationConfig(BaseConfigurationSetupManager.java:155) at com.tc.config.schema.setup.BaseConfigurationSetupManager.dsoApplicationConfigFor(BaseConfigurationSetupManager.java:147) at com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:224) at com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:182) at com.tc.object.bytecode.hook.impl.DSOContextImpl.getGlobalConfigHelper(DSOContextImpl.java:322) at com.tc.object.bytecode.hook.impl.DSOContextImpl.createGlobalContext(DSOContextImpl.java:98) ... 20 more From what I can find in the docs/schema this should still work as expected. Last time I tested with 3.4.0 it worked... I need this as some roots can be obfuscated... so listing them 1 by 1 using <field-name> is not an option right now. From what I can tell from looking into terracotta code, <field-name> MUST be used which is wrong if you look at docs/schema. Please make <field-expression> work again.

    Terracotta Project Issue Tracker | 5 years ago | Andrei Costescu
    java.lang.reflect.InvocationTargetException
  3. 0

    Field-expression for root config no longer works - EXCEPTION

    Terracotta | 5 years ago | costescuandrei
    java.lang.reflect.InvocationTargetException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    New exception after TC & Ehcache upgrade

    Terracotta | 6 years ago | mbrightw
    java.lang.reflect.InvocationTargetException

    Root Cause Analysis

    1. java.lang.NullPointerException

      string is null

      at com.tc.util.Assert.assertNotNull()
    2. com.tc.util
      Assert.assertNotBlank
      1. com.tc.util.Assert.assertNotNull(Assert.java:149)
      2. com.tc.util.Assert.assertNotEmpty(Assert.java:195)
      3. com.tc.util.Assert.assertNotBlank(Assert.java:216)
      4. com.tc.util.Assert.assertNotBlank(Assert.java:227)
      4 frames
    3. com.tc.object
      DSOApplicationConfigObject.<init>
      1. com.tc.object.config.schema.Root.<init>(Root.java:18)
      2. com.tc.object.config.schema.DSOApplicationConfigObject.translateRoots(DSOApplicationConfigObject.java:108)
      3. com.tc.object.config.schema.DSOApplicationConfigObject.<init>(DSOApplicationConfigObject.java:50)
      3 frames
    4. com.tc.config
      BaseConfigurationSetupManager.dsoApplicationConfigFor
      1. com.tc.config.schema.setup.BaseConfigurationSetupManager.createNewDSOApplicationConfig(BaseConfigurationSetupManager.java:155)
      2. com.tc.config.schema.setup.BaseConfigurationSetupManager.dsoApplicationConfigFor(BaseConfigurationSetupManager.java:147)
      2 frames
    5. com.tc.object
      DSOContextImpl.createGlobalContext
      1. com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:224)
      2. com.tc.object.config.StandardDSOClientConfigHelperImpl.<init>(StandardDSOClientConfigHelperImpl.java:182)
      3. com.tc.object.bytecode.hook.impl.DSOContextImpl.getGlobalConfigHelper(DSOContextImpl.java:322)
      4. com.tc.object.bytecode.hook.impl.DSOContextImpl.createGlobalContext(DSOContextImpl.java:98)
      4 frames
    6. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      4. java.lang.reflect.Method.invoke(Unknown Source)
      4 frames
    7. com.tc.object
      ClassProcessorHelper.defineClass0Pre
      1. com.tc.object.bytecode.hook.impl.ClassProcessorHelper.createGlobalContext(ClassProcessorHelper.java:473)
      2. com.tc.object.bytecode.hook.impl.ClassProcessorHelper.initialize(ClassProcessorHelper.java:347)
      3. com.tc.object.bytecode.hook.impl.ClassProcessorHelper.defineClass0Pre(ClassProcessorHelper.java:512)
      3 frames
    8. Java RT
      ClassLoader.loadClass
      1. java.lang.ClassLoader.defineClassCond(Unknown Source)
      2. java.lang.ClassLoader.defineClass(Unknown Source)
      3. java.security.SecureClassLoader.defineClass(Unknown Source)
      4. java.net.URLClassLoader.defineClass(Unknown Source)
      5. java.net.URLClassLoader.access$000(Unknown Source)
      6. java.net.URLClassLoader$1.run(Unknown Source)
      7. java.security.AccessController.doPrivileged(Native Method)
      8. java.net.URLClassLoader.findClass(Unknown Source)
      9. sun.misc.Launcher$AppClassLoader.findClass(Unknown Source)
      10. java.lang.ClassLoader.loadClass(Unknown Source)
      11. sun.misc.Launcher$AppClassLoader.__tc_loadClass(Unknown Source)
      12. sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
      13. java.lang.ClassLoader.loadClass(Unknown Source)
      13 frames