I am trying to prevent my compass (2.2) indexing from inflating lazy hibernate references.
I know there is a setting for this
compass.marshalling.hibernate.initializeProxy
But after a lot of debugging the compass sources I found out, that this setting is not even passed to HibernateProxyExtractor
.
I am applying the setting in my XML config as follows, is this correct?
<bean id="compass" class="org.compass.spring.LocalCompassBean">
<!-- .... -->
<property name="compassSettings">
<prop key="compass.marshalling.hibernate.initializeProxy">false</prop>
<!-- ... -->
</property>
</bean>
While debugging, I found out that DefaultConverterLookup
creates and configures ClassMappingConverter
(which in turn configures ProyExtractorHelper
which in turn configures HibernateProxyExtractor
). However, configuration settings are only passed to ClassMappingConverter
, if they are prefixed with "compass.converter
" (CompassEnvironment.Converter.PREFIX
), which is not the case for compass.marshalling.hibernate.initializeProxy
Note: I am not at all a Compass/Lucene expert, so maybe I just do not get h开发者_如何转开发ow to configure this correctly.
精彩评论