Examples of errorThatOccurred()


Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

  private void handleException(Exception e) {
    log.backendError( e );
    ErrorContextBuilder builder = new ErrorContextBuilder();
    builder.allWorkToBeDone( queue );
    builder.errorThatOccurred( e );
    resources.getErrorHandler().handle( builder.createErrorContext() );
  }

  /**
   * Applies all modifications to the index in parallel using the workers executor
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

          errorContextBuilder.workCompleted( queue.get( i ) );
        }
        catch (ExecutionException e) {
          someFailureHappened = true;
          failedUpdates.add( queue.get( i ) );
          errorContextBuilder.errorThatOccurred( e.getCause() );
        }
      }
      if ( someFailureHappened ) {
        errorContextBuilder.addAllWorkThatFailed( failedUpdates );
        resources.getErrorHandler().handle( errorContextBuilder.createErrorContext() );
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

      //this Runnable splits tasks in more runnables and then runs them:
      processors.runAll( sync );
    } catch ( Exception e ) {
      log.error( "Error in backend", e )
      ErrorContextBuilder builder = new ErrorContextBuilder();
      builder.errorThatOccurred( e );
      errorHandler.handle( builder.createErrorContext() );
    }
  }
 
}
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

    }
    catch ( Throwable tw ) {
      //needs to be attempted even for out of memory errors, therefore we catch Throwable
      log.error( "Unexpected error in Lucene Backend: ", tw );
      try {
        handler.handle( errorContextBuilder.errorThatOccurred( tw ).createErrorContext() );
        workspace.closeIndexWriter();
      }
      finally {
        //LockObtainFailedException is wrapped in a SearchException by the workspace
        //LockObtainFailedException should never ever release the lock
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

  }

  private void handleException(Exception e) {
    ErrorContextBuilder builder = new ErrorContextBuilder();
    builder.allWorkToBeDone( queue );
    builder.errorThatOccurred( e );
    resources.getErrorHandler().handle( builder.createErrorContext() );
  }

  /**
   * Applies all modifications to the index in parallel using the workers executor
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

        catch (ExecutionException e) {
          if ( failedUpdates == null ) {
            failedUpdates = new LinkedList<LuceneWork>();
          }
          failedUpdates.add( queue.get( i ) );
          errorContextBuilder.errorThatOccurred( e.getCause() );
        }
      }
      if ( failedUpdates != null ) {
        errorContextBuilder.addAllWorkThatFailed( failedUpdates );
        resources.getErrorHandler().handle( errorContextBuilder.createErrorContext() );
View Full Code Here

Examples of org.hibernate.search.exception.impl.ErrorContextBuilder.errorThatOccurred()

    }
    catch ( Throwable tw ) {
      //needs to be attempted even for out of memory errors, therefore we catch Throwable
      log.error( "Unexpected error in Lucene Backend: ", tw );
      try {
        handler.handle( builder.errorThatOccurred( tw ).createErrorContext() );
        workspace.closeIndexWriter();
      }
      finally {
        workspace.forceLockRelease();
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.