Package water.H2O

Examples of water.H2O.H2OCountedCompleter


  private void doAllCompletions() {
    final Exception e = _dt.getDException();
    // Also notify any and all pending completion-style tasks
    if( _fjtasks != null )
      for( final H2OCountedCompleter task : _fjtasks )
        H2O.submitTask(new H2OCountedCompleter() {
            @Override public void compute2() {
              if(e != null) // re-throw exception on this side as if it happened locally
                task.completeExceptionally(e);
              else try {
                  task.tryComplete();
View Full Code Here


    // especially it only starts even when fjt completes exceptionally... thus
    // the fjtask onExceptionalCompletion code runs completely before this
    // empty task starts - providing a simple barrier.  Threads blocking on the
    // job will block on the "barrier" task, which will block until the fjtask
    // runs the onCompletion or onExceptionCompletion code.
    _barrier = new H2OCountedCompleter() {
        @Override public void compute2() { }
        @Override public boolean onExceptionalCompletion(Throwable ex, CountedCompleter caller) { return true; }
      };
    fjtask.setCompleter(_barrier);
    _start_time = System.currentTimeMillis();
View Full Code Here

        notifyAll();              // And notify in any case
        final Exception e = _dt.getDException();
        // Also notify any and all pending completion-style tasks
        if( _fjtasks != null )
          for( final H2OCountedCompleter task : _fjtasks )
            H2O.submitTask(new H2OCountedCompleter() {
                @Override protected void compute2() {
                  if(e != null) // re-throw exception on this side as if it happened locally
                    task.completeExceptionally(e);
                  else try {
                    task.tryComplete();
View Full Code Here

TOP

Related Classes of water.H2O.H2OCountedCompleter

Copyright © 2018 www.massapicom. 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.