[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: ClassInfo being serializable

adrian@jboss.org do-not-reply at jboss.com
Wed Jul 11 07:57:25 EDT 2007


No. You don't want an instance of TypeInfoFactory for every type
which is what will happen if you implement (b).

That will lead to multiple caches each with their own versions of the 'same" object.
What a waste of memory.

The IntrospectionTypeInfoFactoryImpl is already a singleton if you look at it
properly. The singleton is held in the wrapper IntrospectionTypeInfoFactory
for exactly the reason that even if two people construct their own,
you don't want multiple versions of the data. They share the data.

The solution should just involve reconnecting to that singleton (from the reflect
implementation of ClassInfo) during deserialization.

You should just disable the serialization tests for the javassist versions
and it to its outstanding jira tasks.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4062933#4062933

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4062933



More information about the jboss-dev-forums mailing list