File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Lucene re-index problem

 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When re-indexing lucene, if there are a certain number of posts, for example 300 posts, the re-index function could process successfully. However, if there are only a few posts, for example 5 posts, the re-index failed whether by date or by message ID. After re-indexing, the Number of documents always displays 0 (if select "Recreate index from scratch"), and go to the lucene index folder, there was no any index files but 'segments.gen' and 'segments_1x'. Please give me any clue. Thanks a lot.
[originally posted on jforum.net by collin_chu]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the following post: http://www.coderanch.com/t/578196 #19543, bmcguire gave a solution for the problem of recreating search index. It can also resolve my problem. But I'm afraid that this solution would impact the re-indexing performance, especially when there are a large number of posts.
[originally posted on jforum.net by collin_chu]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah, unfortunately, using Lucene was new with 2.1.8... and Raphael is the one who knows it best... but he's spending all his limited time on 3.0. Sigh.. we just probably should try to get some people together with time to create a 2.1.9 with critical patches... but...


[originally posted on jforum.net by monroe]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you, monroe, for taking time to look at my concern.
[originally posted on jforum.net by collin_chu]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This bit me as well.

BTW of the two possible solutions for this:
1. This one - http://www.coderanch.com/t/578196 #19543,
2. This one - http://www.andowson.com/trac/jforum/ticket/6

The first one is way faster in all of my testing but it looks like the second solution is "preferred." Any idea why?

I've also found a secondary bug which is that if your first topic_id is > 50 then reindexing fails unless you set the start_Id as 50. The reason is because the code looks for posts in batches of 50. If the first one (1-50) returns no rows is exits without indicating a problem. Fix would be to change the firstPostId such that it gets the min ID from the jforum_topics table and if the number is higher than the user provided one uses that number.
[originally posted on jforum.net by chhum]
 
saverios mahmud
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Thanks for the answers, but both links:

http://www.coderanch.com/t/578196 #19543,
and
http://www.andowson.com/trac/jforum/ticket/6

seem to be broken. Any idea why?

 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 33694
316
Eclipse IDE Java VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
saverios mahmud wrote:Hi,

Thanks for the answers, but both links:

http://www.coderanch.com/t/578196 #19543,
and
http://www.andowson.com/trac/jforum/ticket/6

seem to be broken. Any idea why?


The first one is down because jforum.net no longer has forums up. We've migrated their data. (We will look to see if there is anything we can do to help find the relevant links here more easily. In the meantime, I suggest searching this forum. We know the post is in it.

Andowson's domain is up so you can ask them about the broken link.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 33694
316
Eclipse IDE Java VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Some progress. We now have a page that lists the mapping between all jforum.net URLs and coderanch URLs
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic