-->
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.  [ 6 posts ] 
Author Message
 Post subject: SimpleIndexingProgressMonitor not logging progress
PostPosted: Sat Nov 05, 2011 7:05 am 
Beginner
Beginner

Joined: Sun Sep 18, 2011 4:44 pm
Posts: 22
As for the documentation, I understand that the SimpleIndexingProgressMonitor should print every once in a while a progress message, but I only get start and end messages:

10:10:29,861 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (Hibernate Search: identifierloader-1) HSEARCH000027: Going to reindex 2 entities
10:10:29,872 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (Hibernate Search: identifierloader-1) HSEARCH000027: Going to reindex 7 entities
10:10:29,879 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (Hibernate Search: identifierloader-1) HSEARCH000027: Going to reindex 45354 entities
10:10:29,871 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (Hibernate Search: identifierloader-1) HSEARCH000027: Going to reindex 137331 entities
10:10:29,879 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (Hibernate Search: identifierloader-1) HSEARCH000027: Going to reindex 5594 entities
11:06:06,734 INFO [org.hibernate.search.impl.SimpleIndexingProgressMonitor] (http-localhost.localdomain-127.0.0.1-8080-1) HSEARCH000028: Reindexed 188288 entities

The process takes about an hour and I would like to know the progress.

That is how I use it:
FullTextEntityManager fullTextEntityManager = Search
.getFullTextEntityManager(entityManager);
MassIndexer mi = cl == null ? fullTextEntityManager.createIndexer()
: fullTextEntityManager.createIndexer(Class.forName(cl));
mi.batchSizeToLoadObjects(1000).cacheMode(CacheMode.IGNORE)
.threadsToLoadObjects(5).threadsForIndexWriter(10)
.threadsForSubsequentFetching(15)
.progressMonitor(new SimpleIndexingProgressMonitor()).startAndWait();

I also tried new SimpleIndexingProgressMonitor(10), no difference.

Why is there no logging during the process?
Hibernate Search 4.0.0.CR1.

Thanks


Top
 Profile  
 
 Post subject: Re: SimpleIndexingProgressMonitor not logging progress
PostPosted: Mon Nov 07, 2011 5:39 am 
Hibernate Team
Hibernate Team

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

thanks for reporting this. Looks like a regression. I created - https://hibernate.onjira.com/browse/HSEARCH-966


Top
 Profile  
 
 Post subject: Re: SimpleIndexingProgressMonitor not logging progress
PostPosted: Mon Nov 07, 2011 3:30 pm 
Hibernate Team
Hibernate Team

Joined: Thu Apr 05, 2007 5:52 am
Posts: 1689
Location: Sweden
Will be fixed in CR2. See Jira issue


Top
 Profile  
 
 Post subject: Re: SimpleIndexingProgressMonitor not logging progress
PostPosted: Tue Jan 10, 2012 5:14 am 
Newbie

Joined: Tue Jan 10, 2012 4:27 am
Posts: 2
I'm experiencing the same problem again in 4.0.0.Final.
Could it be possible that it re-disappeared?

I went back to 4.0.0.CR2 where it works perfectly as expected


Top
 Profile  
 
 Post subject: Re: SimpleIndexingProgressMonitor not logging progress
PostPosted: Tue Jan 10, 2012 6:15 am 
Hibernate Team
Hibernate Team

Joined: Thu Apr 05, 2007 5:52 am
Posts: 1689
Location: Sweden
Looking into it ...


Top
 Profile  
 
 Post subject: Re: SimpleIndexingProgressMonitor not logging progress
PostPosted: Fri Feb 03, 2012 11:07 am 
Newbie

Joined: Tue Jan 10, 2012 4:27 am
Posts: 2
I could narrow it down now I think.
I'm running the complete re-indexing like this

Code:
@Test
public void runMassIndexer() {
   try {
      Search.getFullTextSession(sessionFactory.getCurrentSession()).flushToIndexes();
      Search.getFullTextSession(sessionFactory.getCurrentSession()).createIndexer().purgeAllOnStart(true).cacheMode(CacheMode.IGNORE)
            .optimizeOnFinish(true).startAndWait();
   } catch (HibernateException e) {
      fail("HibernateException while rebuilding the lucene index");
   } catch (InterruptedException e) {
      fail("InterruptedException while rebuilding the lucene index");
   }
}


Which is not working anymore.
However when I start the indexer with just a single class as argument for "createIndexer()" it works.
No matter which of my "@Indexed"-marked classes I enter there.

If I enter a second class its not working. Hope this could help


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