Hi,
not sure whether we can get rid of WeakIdentityHashMap. There are other
uses for this class
not only ContextHolder. However, I think we could remove ContextHolder and
FullTextIndexCollectionEventListener.
The default constructor in FullTextIndexEventListener could be deprecated
and throw a
SearchException to ensure people remove the explicit listener
configuration from their
config files.
I've attached a patch in case. Have a look at let me know what you think.
If we go ahead with these changes we have to move the enableXYZ
(enableBeanValidation,
enableHibernateSearch,enableLegacyHibernateValidator) from
AnnotationConfiguration.buildSessionFactory
into Configuration.buildSessionFactory.
Comments?
--Hardy
On Mon, 12 Jul 2010 14:36:09 +0200, Sanne Grinovero
<sanne.grinov...@gmail.com> wrote:
2010/7/12 Hardy Ferentschik <hibern...@ferentschik.de>:
Hi Sanne,
I guess you are referring to HSEARCH-517 and the WeakHashMap in
ContextHolder.
Reading through the comments I am wondering whether we couldn't
deprecate
the default constructor in FullTextIndexEventListener now? The
annotation module in Core has now been merged with the core module so
ContextHolder seems obsolete.
I am all up for it especially if this opens the door to exposing the
configuration
properties in SearchFactory.
+1
I've also had many needs for the configuration in the past, it's
always been hard to workaround this limitation, and harder yet to make
sure we wouldn't leak memory (and I'm still not convinced about that).
Also then we could remove
org.hibernate.search.util.WeakIdentityHashMap, a hard to understand
and to maintain class.
_______________________________________________
hibernate-dev mailing list
hibernate-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev