Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 379 for cancel0 (0.16 sec)

  1. okhttp/src/test/java/okhttp3/internal/connection/FastFallbackExchangeFinderTest.kt

        taskFaker.advanceUntil(500.ms)
        assertEvents(
          "take plan 2",
          "plan 0 cancel",
          "plan 1 cancel",
        )
    
        taskFaker.advanceUntil(510.ms)
        assertEvents(
          "plan 1 TCP connect canceled",
        )
    
        taskFaker.advanceUntil(520.ms)
        assertEvents(
          "plan 0 TCP connect canceled",
        )
      }
    
      @Test
      fun takeMultipleConnections() {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Wed Apr 24 04:40:49 UTC 2024
    - 20.9K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http/CancelTest.kt

        listener.clearAllEvents()
    
        assertThat(events).startsWith("CallStart", "ConnectStart", "ConnectEnd", "ConnectionAcquired")
        if (cancelMode == CANCEL) {
          assertThat(events).contains("Canceled")
        } else {
          assertThat(events).doesNotContain("Canceled")
        }
        assertThat(events).contains("ResponseFailed")
        assertThat(events).contains("ConnectionReleased")
    
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  3. internal/grid/connection.go

    	c.updateState(StateConnected)
    	ctx, cancel := context.WithCancelCause(ctx)
    	defer cancel(ErrDisconnected)
    
    	// This will ensure that is something asks to disconnect and we are blocked on reads/writes
    	// the connection will be closed and readers/writers will unblock.
    	go c.monitorState(conn, cancel)
    
    	c.handleMsgWg.Add(2)
    	c.reconnectMu.Unlock()
    
    	// Read goroutine
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Jun 07 15:51:52 UTC 2024
    - 44.8K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/ws/RealWebSocketTest.kt

          }
          try {
            sink.close()
          } catch (ignored: IOException) {
          }
          closed = true
        }
    
        override fun cancel() {
          canceled = true
          sourcePipe.cancel()
          sinkPipe.cancel()
        }
      }
    
      companion object {
        private fun ns(millis: Long): Long {
          return millis * 1000000L
        }
      }
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Thu Apr 11 01:59:58 UTC 2024
    - 18.5K bytes
    - Viewed (0)
  5. src/crypto/tls/quic.go

    	eventArr [8]QUICEvent
    
    	started  bool
    	signalc  chan struct{}   // handshake data is available to be read
    	blockedc chan struct{}   // handshake is waiting for data, closed when done
    	cancelc  <-chan struct{} // handshake has been canceled
    	cancel   context.CancelFunc
    
    	waitingForDrain bool
    
    	// readbuf is shared between HandleData and the handshake goroutine.
    	// HandshakeCryptoData passes ownership to the handshake goroutine by
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 17:23:54 UTC 2024
    - 15.1K bytes
    - Viewed (0)
  6. internal/logger/target/http/http.go

    		atomic.AddInt64(&h.failedMessages, 1)
    		return errors.New("log buffer full")
    	}
    
    	return nil
    }
    
    // Cancel - cancels the target.
    // All queued messages are flushed and the function returns afterwards.
    // All messages sent to the target after this function has been called will be dropped.
    func (h *Target) Cancel() {
    	atomic.StoreInt32(&h.status, statusClosed)
    	h.storeCtxCancel()
    
    	// Wait for messages to be sent...
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Sun Jun 02 03:03:39 UTC 2024
    - 14.9K bytes
    - Viewed (0)
  7. src/net/lookup_test.go

    		// GODEBUG=netdns=go.
    		N = 500
    	}
    
    	const timeout = 3 * time.Second
    	ctxHalfTimeout, cancel := context.WithTimeout(context.Background(), timeout/2)
    	defer cancel()
    	ctxTimeout, cancel := context.WithTimeout(context.Background(), timeout)
    	defer cancel()
    
    	c := make(chan error, 2*N)
    	for i := 0; i < N; i++ {
    		name := fmt.Sprintf("%d.net-test.golang.org", i)
    		go func() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 41.4K bytes
    - Viewed (0)
  8. src/os/exec/exec_test.go

    }
    
    func TestCancelErrors(t *testing.T) {
    	t.Parallel()
    
    	// If Cancel returns a non-ErrProcessDone error and the process
    	// exits successfully, Wait should wrap the error from Cancel.
    	t.Run("success after error", func(t *testing.T) {
    		t.Parallel()
    
    		ctx, cancel := context.WithCancel(context.Background())
    		defer cancel()
    
    		cmd := helperCommandContext(t, ctx, "pipetest")
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 20:13:53 UTC 2024
    - 48.4K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiserver/pkg/admission/plugin/webhook/validating/dispatcher.go

    	defer span.End(500 * time.Millisecond)
    
    	// if the webhook has a specific timeout, wrap the context to apply it
    	if h.TimeoutSeconds != nil {
    		var cancel context.CancelFunc
    		ctx, cancel = context.WithTimeout(ctx, time.Duration(*h.TimeoutSeconds)*time.Second)
    		defer cancel()
    	}
    
    	r := client.Post().Body(request)
    
    	// if the context has a deadline, set it as a parameter to inform the backend
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Aug 23 20:24:12 UTC 2023
    - 13K bytes
    - Viewed (0)
  10. internal/dsync/dsync_test.go

    	ctx, cancel := context.WithCancel(context.Background())
    
    	if !dm.GetLock(ctx, cancel, id, source, Options{Timeout: 5 * time.Minute}) {
    		t.Fatal("GetLock() should be successful")
    	}
    
    	// Make it run twice.
    	timer := time.NewTimer(testDrwMutexRefreshInterval * 2)
    
    	select {
    	case <-ctx.Done():
    		t.Fatal("Lock context canceled which is not expected")
    	case <-timer.C:
    	}
    
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Sat Dec 24 03:49:07 UTC 2022
    - 11K bytes
    - Viewed (0)
Back to top