Failed to generate dynamic type

#1

Hi 

I was trying to enhance some of my classes and I got an error : 

Failed to generate dynamic type com.package.RootContainer (error 361)

It seems that all dependent classes are on the classpath , so what is missing or how to recognize what is wrong with that class ??

thanks in advance

b

#2

one more thing ....  : how to increase Enhancer log level ??

 

thanks

b

#3

In case of JPA API we can specify persistence unit, can we do the same in case of JDO? can we specify with that option file package.jdo?

 

in a doc there is output from enhancer

[ObjectDB 2.0]
3 persistable types have been enhanced:
test.MyEntity1
test.MyEntity2
test.MyEmbeddable
2 NON persistable types have been enhanced:
Main
test.Manager

 

what does it means : "2 NON persistable types have been enhanced:"

br

Tomasz

#4

hi

 

regarding better logging .... it is really needed as I finnally got something like that : 

 

[ObjectDB 2.2.8_02] null

 

What "null" ?? some class is missing ... or you are unable to process that file ??

reagrds

b

#5

I konw the cause of message "[ObjectDB 2.2.8_02] null"

enhanced class has a static initializer:

static {
        sLogger = Logger.getInstance();
    }

 

after commenting out that line  I got next laconic error, probably MullPointerException is raised from that line, NPE has message equal to null. For now we can comment this line but better logging is essential next error is:

[echo] post build
        [java] [ObjectDB 2.2.8_02] com.packagename.IEnvironment

and i have no idea what to do

br

Tomasz

 

 

#6

This thread contains a combination of bug reports / feature requests / support questions.

Please use a separate thread for every topic and use the issue tracking for clear ObjectDB bugs.

Regarding logging - the ordinary ObjectDB log file should contain a full stack trace of the Enhancer exception, at least when you run command line enhancement. Build 2.2.8_08 adds information about the type (adding information about the exact field is more difficult, since most exceptions are caused during loading of a class by the JVM, for example because of a missing type, and reference to the relevant field is unavailable).

The static initializer issue cannot be reproduced with a simple empty static initializer. Maybe your static initializer throws an exception when the class is loaded during enhancement? If not, please provide a sample case that demonstrates the problem.

Please create separate forum threads with descriptive titles for questions regarding enhancement (and please read these posting instructions).

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
#7

yes our static initializer thew exception during class loading, we corrected that, but enancer could print message that during classloading there was a problem and give exception name and message, it is hard to improve error, having only message which is equal to null

thank you, we will check 2.2.8_08


Post Reply

To post a reply and/or subscribe to update notifications - please login