[hibernate-issues] [Hibernate-JIRA] Commented: (HSEARCH-444) Search fails to start when core uses XML mappings making use of entity-name attribute
Emmanuel Bernard (JIRA)
noreply at atlassian.com
Tue Feb 1 07:56:05 EST 2011
[ http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=39792#action_39792 ]
Emmanuel Bernard commented on HSEARCH-444:
------------------------------------------
The patches so far don't really cover all the changes required so they won't make it in as is. We can't put a half-done feature in as it would break people's expectation.
A proper patch would need to:
- make use of entity-name when needed all the way to the index (today the entity class name is used): the initial patch implies a one to one match between a class and an entity-name but this assumption seems too restrictive
- make sure all object initialization options make use of entity-name when needed
I don't think the team have time to work on it any time soon but if someones step up and propose some patch / pull-request on github, we will gladly help.
> Search fails to start when core uses XML mappings making use of entity-name attribute
> -------------------------------------------------------------------------------------
>
> Key: HSEARCH-444
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-444
> Project: Hibernate Search
> Issue Type: Bug
> Components: mapping
> Affects Versions: 3.1.0.GA
> Reporter: Sanne Grinovero
> Assignee: Emmanuel Bernard
> Attachments: HSEARCH-444_partial_1-1_bridge_between_entity-name_and_class.patch
>
>
> As described on forums: https://forum.hibernate.org/viewtopic.php?f=9&t=993687
> classes mapped using XML on hibernate core, like
> classes starting with:
> <class name="com.mydomain.myapp.AnswerImpl" table="answer"
> entity-name="Answer">
> cause:
> Caused by: java.lang.NullPointerException
> at org.hibernate.search.cfg.SearchConfigurationFromHibernateCore.getClassMapping(SearchConfigurationFromHibernateCore.java:31)
> at org.hibernate.search.store.DirectoryProviderFactory.getDirectoryProviderName(DirectoryProviderFactory.java:226)
> at org.hibernate.search.store.DirectoryProviderFactory.createDirectoryProviders(DirectoryProviderFactory.java:53)
> at org.hibernate.search.impl.SearchFactoryImpl.initDocumentBuilders(SearchFactoryImpl.java:404)
> at org.hibernate.search.impl.SearchFactoryImpl.<init>(SearchFactoryImpl.java:119)
> at org.hibernate.search.event.ContextHolder.getOrBuildSearchFactory(ContextHolder.java:30)
> at org.hibernate.search.event.FullTextIndexEventListener.initialize(FullTextIndexEventListener.java:59)
> at org.hibernate.event.EventListeners$1.processListener(EventListeners.java:198)
> at org.hibernate.event.EventListeners.processListeners(EventListeners.java:181)
> at org.hibernate.event.EventListeners.initializeListeners(EventListeners.java:194)
> ... 16 more
> This was reported on 3.1.0.GA but I guess it affects all releases.
> There's a "test WAR" in the forums, going to ask for a testcase.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list