thanks for sharing the code.
I have implemented first 2 points too, but looking at your code I have
changed ServiceRegistry management in JDBCMetaDataConfiguration today.
If you are interested my code is here:
I have found 1 memory leak in your code:
it's in ServiceRegistryHelper map. Either you should use WeakReferences
there or you should not use the Map<Configuration, ServiceRegistry> as
/JDBCMetaDataConfiguration config = new JDBCMetaDataConfiguration ();
will create another key-value pair in the map. But the snippet is
created for every exporters run.
Another problem is that the ServiceRegistry implements
ServiceRegistryImplementor it should be properly destroyed (this allows
it to clean up system resources). And seems my code is also not free
from the forgotten not stopped service registry.
07/10/2011 16:15, Strong Liu wrote:
okay, i pushed it to my fork https://github.com/stliu/hibernate-tools
I didn't try to get rid of Configuration, since it's still the only way to get to
SF (new metamodel is not in place yet)
but there are others:
1. package change
3. Junit 4
On Oct 7, 2011, at 8:05 PM, Dmitry Geraskov wrote:
> Hi, Strong Liu,
> can I somehow look at you "draft" hibernate tools for hibernate core 4
> You said there are a lot of code should be rewritten, I guess you try to get rid of
> My approach was: minimal changes and still use the Configuration class.
> Dmitry Geraskov
> 06/10/2011 20:05, Strong Liu wrote:
>> I'm in the middle of moving hibernate tools to use hibernate4
>> but there are too many codes need to be changed (well, almost all)
>> I guess you won't like my pull request :(
>> Strong Liu<stliu(a)hibernate.org>
>> On Oct 6, 2011, at 11:37 PM, Max Rydahl Andersen wrote:
>>> On Sep 30, 2011, at 20:01, Gail Badner wrote:
>>>> There have been a couple of comments about problems with eclipse
integration with Hibernate 3.6.7:
>>>> I don't use Eclipse myself. Does anyone have an answer?
>>> It's not just Eclipse, its any Hibernate tools usage that have the
>>> Hibernate 3.6 breaks API so we can't build console configurations and
>>> without recompiling and if we do that we won't work with Hibernate
>>> Same problem with Hibernate 4.
>>> Now when Hibernate 4 is keeping Configuration it becomes somewhat more
possible to support
>>> Hibernate 3.5 and Hibernate 4…but its rather messy unfortunately ;(
>>> Dima is working on solving some of this but its still very experimental.
>>> If anyone got time to help out we very much welcome it!
>>> hibernate-dev mailing list
>> hibernate-dev mailing list