-->
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.  [ 3 posts ] 
Author Message
 Post subject: Hibernate Search indices
PostPosted: Thu Jul 08, 2010 11:14 pm 
Newbie

Joined: Mon Oct 26, 2009 3:38 pm
Posts: 18
I recently implemented Hibernate Search. In the indexBase directory a subdirectory matching the fully qualified name of the hibernate search annotated entity class was created. This subdirectory contains the following files, can some explain what these files are and their role in the index?
Quote:
_0.cfs
_1.cfs
segments_3
segments.gen
Also, does anyone know how to specify the name of the index rather than relying on the fully qualified name as the default index name?


Top
 Profile  
 
 Post subject: Re: Hibernate Search indices
PostPosted: Fri Jul 09, 2010 3:01 am 
Pro
Pro

Joined: Wed Oct 03, 2007 2:31 pm
Posts: 205
Quote:
Also, does anyone know how to specify the name of the index rather than relying on the fully qualified name as the default index name?


You can override the default name of the index by using the index attribute on the Indexed annotation. For example:
Code:
@Entity
@Indexed(index="indexes/essays")
public class Essay {
   ...
}


As for your first question I would recommend reading the following:

http://lucene.apache.org/java/2_0_0/fileformats.html

The link provides an explaination to the core concepts of the files generated by Lucene.


Hope that helps.

Amiin


Top
 Profile  
 
 Post subject: Re: Hibernate Search indices
PostPosted: Mon Jul 12, 2010 7:52 pm 
Newbie

Joined: Mon Oct 26, 2009 3:38 pm
Posts: 18
amin-mc wrote:
Hope that helps.

Amiin
Thanks a bunch. I guess I mis-read the Hibernate Search documentation, because I thought the "name" not the "index" attribute set the directory name of the index. Also, the Lucene file format link helped me understand the core files of the index.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 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.