Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 283 for pcancel (0.12 sec)

  1. android/guava-tests/test/com/google/common/util/concurrent/FuturesTransformAsyncTest.java

        inputFuture.cancel(true); // argument is ignored
        assertThrows(CancellationException.class, () -> resultFuture.get());
      }
    
      public void testFutureGetThrowsCancellationIfOutputCancelled() throws Exception {
        inputFuture.set(SLOW_OUTPUT_VALID_INPUT_DATA);
        outputFuture.cancel(true); // argument is ignored
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/util/concurrent/FuturesTransformAsyncTest.java

        inputFuture.cancel(true); // argument is ignored
        assertThrows(CancellationException.class, () -> resultFuture.get());
      }
    
      public void testFutureGetThrowsCancellationIfOutputCancelled() throws Exception {
        inputFuture.set(SLOW_OUTPUT_VALID_INPUT_DATA);
        outputFuture.cancel(true); // argument is ignored
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/connection/RealCall.kt

       * if a socket connection is being established, that is terminated.
       */
      override fun cancel() {
        if (canceled) return // Already canceled.
    
        canceled = true
        exchange?.cancel()
        for (plan in plansToCancel) {
          plan.cancel()
        }
    
        eventListener.canceled(this)
      }
    
      override fun isCanceled(): Boolean = canceled
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 17.9K bytes
    - Viewed (0)
  4. internal/grid/stream.go

    // If the context is canceled, the stream will be canceled.
    func (s *Stream) Results(next func(b []byte) error) (err error) {
    	done := false
    	defer func() {
    		if s.cancel != nil {
    			s.cancel(err)
    		}
    
    		if !done {
    			// Drain channel.
    			for range s.responses {
    			}
    		}
    	}()
    	doneCh := s.ctx.Done()
    	for {
    		select {
    		case <-doneCh:
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Jun 07 15:51:52 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/util/concurrent/TimeoutFuture.java

       * write.
       *
       * 2. visibility of the writes to an afterDone() call triggered by cancel():
       *
       * Since these fields are non-final that means that TimeoutFuture is not being 'safely published',
       * thus a motivated caller may be able to expose the reference to another thread that would then
       * call cancel() and be unable to cancel the delegate.
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 25 13:13:32 UTC 2024
    - 8.1K bytes
    - Viewed (0)
  6. internal/dsync/drwmutex.go

    			}
    		}
    	}
    }
    
    func (dm *DRWMutex) startContinuousLockRefresh(lockLossCallback func(), id, source string, quorum int) {
    	ctx, cancel := context.WithCancel(context.Background())
    
    	dm.m.Lock()
    	dm.cancelRefresh = cancel
    	dm.m.Unlock()
    
    	go func() {
    		defer cancel()
    
    		refreshTimer := time.NewTimer(dm.refreshInterval)
    		defer refreshTimer.Stop()
    
    		for {
    			select {
    			case <-ctx.Done():
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 09 15:49:49 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  7. internal/grid/grid_test.go

    		// Fill up queue.
    		for sendReq {
    			select {
    			case st.Requests <- []byte("Hello"):
    				time.Sleep(10 * time.Millisecond)
    			default:
    				sendReq = false
    			}
    		}
    		cancel()
    		<-serverCanceled
    		t.Log("server cancel time:", time.Since(start))
    		clientEnd := <-clientCanceled
    		if !errors.Is(err, context.Canceled) {
    			t.Error("expected context.Canceled, got", err)
    		}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Jul 29 18:10:04 UTC 2024
    - 36.4K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2ExchangeCodec.kt

        stream = http2Connection.newStream(requestHeaders, hasRequestBody)
        // We may have been asked to cancel while creating the new stream and sending the request
        // headers, but there was still no stream to close.
        if (canceled) {
          stream!!.closeLater(ErrorCode.CANCEL)
          throw IOException("Canceled")
        }
        stream!!.readTimeout().timeout(chain.readTimeoutMillis.toLong(), TimeUnit.MILLISECONDS)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 6.9K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/util/concurrent/ExecutionSequencerTest.java

        // stop it.
        blockingCallable.waitForStart();
    
        // This time, cancel the future for the first task. The task remains running, only the future
        // is cancelled.
        future1.cancel(false);
    
        // Give the second task a chance to (incorrectly) start up while the first task is running.
        // (This is the assertion that fails.)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 22:10:29 UTC 2024
    - 16.7K bytes
    - Viewed (0)
  10. cmd/iam-etcd-store.go

    	m[policy] = p
    	return nil
    }
    
    func (ies *IAMEtcdStore) loadPolicyDocs(ctx context.Context, m map[string]PolicyDoc) error {
    	ctx, cancel := context.WithTimeout(ctx, defaultContextTimeout)
    	defer cancel()
    	//  Retrieve all keys and values to avoid too many calls to etcd in case of
    	//  a large number of policies
    	r, err := ies.client.Get(ctx, iamConfigPoliciesPrefix, etcd.WithPrefix())
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 15 01:29:20 UTC 2024
    - 14K bytes
    - Viewed (0)
Back to top