Simon Spero wrote:

And if that is the case it will be really hard to optimize it away since the classloading and proxification is required and non-serializable and thus non-avoidable....at least as things works and looks like now ;(

Still - any suggestions are welcome ;)


If the configuration is static and the byte code for the persistent classes is also unchanged, isn't the output from code generation also going to be constant?

Not always! Your classes can change signature without affecting the configuration, thus redoing proxification is the safest thing to do - at least during development.


If this is the case, could you dump the generated byte code into class files and store those as part of the freezing process?

It is not a bad idea for the class part (which are serializable), but it is all the stuff that is derived from these classes that is hard to de-serialize. Stuff like Method, Constructor, CacheStrategy, IdentifierGenerator is all hard to re-associate/re-build since they need access to the SessionFactory to regain their proper place - and as it is the SessionFactory we would serialize we would have some serious challenges accessing that information during deserialization......we would probably need some kind of "second-pass" serialization or consider "beefing" up the relevant parts with more information (but that would increase the coupling of things and the memory consumption + complicate the code a great deal).


...but your suggestion is a valid one and I'll go see if it is somehow doable....

It would be reaaally nice if someone could provide me with a very slow loading set of hbm.xml files + classes as it would really make it easier to pinpoint hotspots...With all of hibernate's testing classes and a bunch of my own (approx 60) the loading takes 5-6 seconds...

/max






-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. Take an Oracle 10g class now, and we'll give you the exam FREE. http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
_______________________________________________
hibernate-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to