0
votes

I want to know how lucene index text and store on files. I try to find its source code but what I found it high level source code not basic source code. For instance I am looking for class indexer or indexWriter which create and write the index but I could not. Would you please help we find the main source code of Lucene?

I downloaded the code from http://lucene.apache.org/core/ but I could not find the codes I need. I read following references but they are not helpful too.

http://svn.apache.org/repos/asf/lucene/dev/trunk/lucene/core/src/java/org/apache/lucene/codecs/

http://oak.cs.ucla.edu/cs144/projects/lucene/

http://lucene.apache.org/core/3_0_3/fileformats.html

2
Why should I get -1 for this post?user3487667
Questions asking for off-site resources are off-topic. Your question is also very broad (the last link you posted should have been ample to demonstrate this topic's complexity).femtoRgon
@femtoRegon Thanks for explenationuser3487667

2 Answers

3
votes

I think it is naïve to expect that somehow the whole indexing should fit in a single class. Before understanding classes you should first understand high-level concepts. Classes are just narrow tiny puzzles plugged into a large framework.

In particular, if you are interested in the Lucene codecs, you should read this first. Then you could look at the unit test and run/debug/step over on your machine to see how things work. The next thing would be to implement slightly altered version of standard postings format and see how it goes.

Your mentioned locations (http://svn.apache.org) indeed contain Lucene source code, so does downloadables from http://lucene.apache.org/core, don't look anywhere else.

0
votes

It's open source and you can pick any of the mirrors mentioned on their website to download the source code.