-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Hibernate Search with multiple filters
PostPosted: Tue Apr 05, 2011 4:00 pm 
Newbie

Joined: Tue Nov 09, 2010 4:42 pm
Posts: 7
Hi,

We're having a problem that has proven very difficult to track down. We are using hibernate search in conjunction with filters, which works very nicely. However, when enabling multiple filters, there seems to be an issue. Specifically, we have a lucene query with two filters enabled on it. The query itself restricts the results to 3 entities, which is correct. Either filter, when enabled individually, does not further restrict the results. That is, neither filter actually filters anything. This is also the correct and expected behaviour for the particular results being returned by the given query. However, when BOTH filters are enabled, one of the results is filtered out, which is certainly NOT the expected behaviour, since it wasn't filtered out by either of them individually.

We've had trouble making any progress in debugging the issue. Can anyone shed some light on what might be a potential source of the problem? It seems like a pretty straight-forward setup, so I'm concerned that we're hitting some hibernate search bug of some kind. At the same time, though, since it is relatively simple, that seems unlikely.

Any thoughts would be appreciated.


Last edited by Obsidians on Wed Apr 06, 2011 9:21 am, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Hibernate Search with multiple filters
PostPosted: Wed Apr 06, 2011 4:06 am 
Hibernate Team
Hibernate Team

Joined: Thu Apr 05, 2007 5:52 am
Posts: 1689
Location: Sweden
Hi,

that sounds definitely fishy. Filters are chained and if none of the filters further restrict the results nothing should happen.
That said, I remember an issue related to AndDocIdSet which we internally use to combine the bit sets of the chained filters (HSEARCH-610). Which version of Search are you using? It should be fixed in Search 3.3.0.Final

If this is not the problem we would really see the code or even better you would provide us w/ a testcase to replicate the problem.

--Hardy


Top
 Profile  
 
 Post subject: Re: Hibernate Search with multiple filters
PostPosted: Wed Apr 06, 2011 9:21 am 
Newbie

Joined: Tue Nov 09, 2010 4:42 pm
Posts: 7
We're using Seam2, so our Hibernate Search is 3.1.1.GA. I'll look into updating it, although that may be.... messy. Thanks for the help.


Top
 Profile  
 
 Post subject: Re: Hibernate Search with multiple filters
PostPosted: Wed Apr 06, 2011 3:01 pm 
Hibernate Team
Hibernate Team

Joined: Fri Oct 05, 2007 4:47 pm
Posts: 2536
Location: Third rock from the Sun
Later Hibernate Search versions are drop-in replacements for the older one. The only issue you could face is that this needs an upgrade of hibernate core.

Some minor details which might affect your app are described here, but there are no known compatibilities with Seam:
http://community.jboss.org/wiki/HibernateSearchMigrationGuide

The Lucene dependencies are a mess, they change jar and packaging quite often, and the Lucene API also changes very often, but Seam does never depend on them directly: use the Search API as a "shield".

Actually the latest Seam2 is using a later version of Search (don't remember which one, might be 3.3.0)

_________________
Sanne
http://in.relation.to/


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.