[KinoSearch] revision 3552 SEGV during indexing

Marvin Humphrey marvin at rectangular.com
Thu Jul 3 07:49:54 PDT 2008




On Jul 3, 2008, at 1:06 AM, Henry wrote:

> eval {
>  ...
>  my $doc = {};
>  $doc->{title} = gettext1();
>  $doc->{body}  = gettext2();
>  ...
>  print Dumper $doc;   # <----- without this, the indexer drops a core
>  my $ksdoc = KinoSearch::Doc->new(
>      fields => $doc,
>      boost  => $doc_boost);
>  $invindexer->add_doc($ksdoc)
> };

Thanks for the sample.  Unfortunately, I have yet to duplicate the  
problem.  I tried adding a similar loop to t/305-invindexer.t (see  
below), but it ran clean both under normal conditions and under  
valgrind.

Since you run Linux and this problem seems to be happening  
consistently, how about running your app under valgrind?  Something  
should turn up right away.

   valgrind perl myapp.pl

Marvin Humphrey
Rectangular Research
http://www.rectangular.com/

Index: ../perl/t/305-invindexer.t
===================================================================
--- ../perl/t/305-invindexer.t	(revision 3557)
+++ ../perl/t/305-invindexer.t	(working copy)
@@ -21,6 +21,22 @@

  my $invindexer = KinoSearch::InvIndexer->new( invindex =>  
$invindex, );

+for ( 0 .. 10 ) {
+    eval {
+        my $fields = {
+            content => "blah$_",
+        };
+        my $doc = KinoSearch::Doc->new(
+            fields => $fields,
+            boost => $_,
+        );
+        $invindexer->add_doc($doc);
+    }
+}
+$invindexer->finish;
+
+$invindexer = KinoSearch::InvIndexer->new( invindex => $invindex, );
+
  eval {
      my $lock_factory = KinoSearch::Store::LockFactory->new(
          folder   => $folder,

_______________________________________________
KinoSearch mailing list
KinoSearch at rectangular.com
http://www.rectangular.com/mailman/listinfo/kinosearch




More information about the kinosearch mailing list