Ignore:
Timestamp:
2014-01-30T15:11:04+13:00 (10 years ago)
Author:
ak19
Message:

Removed 'die' statements in favour of rint to STDERR to allow the perl process to continue, rather than stopping abruptly.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gs2-extensions/apache-jena/trunk/src/perllib/jenaTDBBuilder.pm

    r28410 r28802  
    9898
    9999    }
    100 
     100   
    101101    # Run the docs through the jenaTDB document processor
    102102
    103103    $self->{'buildproc'}->set_mode ('text');
    104104    $self->{'buildproc'}->reset();
     105
     106    # If '-removeold' in effect (i.e. *not* keepold), then clear out
     107    # the triple-store graph for this collection
     108
     109    if (!$self->{'keepold'}) {
     110    my $collection = $self->{'collection'};
     111    my $cmd = "gs-triplestore-reset $collection";
     112       
     113    my $status = system($cmd);
     114    if ($status == 0) {
     115        print $outhandle "    => removeold: Deleting triplestore graph for $collection\n";
     116    }
     117    else {
     118        print STDERR "Error: failed to run:\n  $cmd\n$!\n";
     119        print STDERR "       Graph has not been deleted\n";
     120    }
     121    }
     122
    105123    &plugin::begin($self->{'pluginfo'}, $self->{'source_dir'},
    106124           $self->{'buildproc'}, $self->{'maxdocs'});
Note: See TracChangeset for help on using the changeset viewer.