Marvin Humphrey > KinoSearch-0.315 > KinoSearch::Object::Err

Download:
KinoSearch-0.315.tar.gz

Dependencies

Annotate this POD

CPAN RT

New  1
Open  4
View/Report Bugs
Source  

NAME ^

KinoSearch::Object::Err - Exception.

DEPRECATED ^

The KinoSearch code base has been assimilated by the Apache Lucy project. The "KinoSearch" namespace has been deprecated, but development continues under our new name at our new home: http://lucy.apache.org/

SYNOPSIS ^

    use Scalar::Util qw( blessed );
    my $bg_merger;
    while (1) {
        $bg_merger = eval {
            KinoSearch::Index::BackgroundMerger->new( index => $index );
        };
        last if $bg_merger;
        if ( blessed($@) and $@->isa("KinoSearch::Store::LockErr") ) {
            warn "Retrying...\n";
        }
        else {
            # Re-throw.
            die "Failed to open BackgroundMerger: $@";
        }
    }

DESCRIPTION ^

Most of the time when KinoSearch encounters an error, it tries to raise a KinoSearch::Object::Err exception with an error message and context information.

At present, it is only safe to catch exceptions which are specifically documented as catchable; most times when an Err is raised, KinoSearch leaks memory.

The Err module also provides access to a per-thread Err shared variable via set_error() and get_error(). It may be used to store an Err object temporarily, so that calling code may choose how to handle a particular error condition.

INHERITANCE ^

KinoSearch::Object::Err isa KinoSearch::Object::Obj.

COPYRIGHT AND LICENSE ^

Copyright 2005-2011 Marvin Humphrey

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

syntax highlighting: