Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 366 for connc (0.05 sec)

  1. src/net/http/transport_internal_test.go

    func TestTransportPersistConnReadLoopEOF(t *testing.T) {
    	ln := newLocalListener(t)
    	defer ln.Close()
    
    	connc := make(chan net.Conn, 1)
    	go func() {
    		defer close(connc)
    		c, err := ln.Accept()
    		if err != nil {
    			t.Error(err)
    			return
    		}
    		connc <- c
    	}()
    
    	tr := new(Transport)
    	req, _ := NewRequest("GET", "http://"+ln.Addr().String(), nil)
    	req = req.WithT(t)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 15:57:17 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  2. src/net/net_test.go

    			t.Parallel()
    
    			ln := newLocalListener(t, network)
    			connc := make(chan Conn, 1)
    			defer func() {
    				ln.Close()
    				for c := range connc {
    					if c != nil {
    						c.Close()
    					}
    				}
    			}()
    			go func() {
    				defer close(connc)
    				c, err := ln.Accept()
    				if err != nil {
    					t.Error(err)
    				}
    				connc <- c // might be nil
    			}()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jan 22 21:04:44 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  3. src/net/dial_test.go

    	const timeoutTick = 100
    
    	var d Dialer
    	cancel := make(chan struct{})
    	d.Cancel = cancel
    	errc := make(chan error, 1)
    	connc := make(chan Conn, 1)
    	go func() {
    		if c, err := d.Dial("tcp", blackholeIPPort); err != nil {
    			errc <- err
    		} else {
    			connc <- c
    		}
    	}()
    	ticks := 0
    	for {
    		select {
    		case <-ticker.C:
    			ticks++
    			if ticks == cancelTick {
    				close(cancel)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Feb 20 06:04:31 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  4. src/net/http/transport_test.go

    					return false
    				}
    			}
    			res.Body.Close()
    			conns := idleConns()
    			if len(conns) != 1 {
    				if len(conns) == 0 {
    					t.Logf("req %v: no idle conns", n)
    					return false
    				}
    				t.Fatalf("req %v: unexpected number of idle conns: %q", n, conns)
    			}
    			if conn == "" {
    				conn = conns[0]
    			}
    			if conn != conns[0] {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 21:59:21 UTC 2024
    - 192.6K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apimachinery/pkg/util/httpstream/wsstream/conn.go

    	conn.selectedProtocol = negotiated[0]
    	p := conn.protocols[conn.selectedProtocol]
    	if p.Binary {
    		conn.codec = rawCodec
    	} else {
    		conn.codec = base64Codec
    	}
    	conn.ws = ws
    	conn.channels = make([]*websocketChannel, len(p.Channels))
    	for i, t := range p.Channels {
    		switch t {
    		case ReadChannel:
    			conn.channels[i] = newWebsocketChannel(conn, byte(i), true, false)
    		case WriteChannel:
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Mar 04 19:10:30 UTC 2024
    - 14.5K bytes
    - Viewed (0)
  6. src/crypto/tls/conn.go

    // After a Write has timed out, the TLS state is corrupt and all future writes will return the same error.
    func (c *Conn) SetDeadline(t time.Time) error {
    	return c.conn.SetDeadline(t)
    }
    
    // SetReadDeadline sets the read deadline on the underlying connection.
    // A zero value for t means [Conn.Read] will not time out.
    func (c *Conn) SetReadDeadline(t time.Time) error {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:10:12 UTC 2024
    - 51.8K bytes
    - Viewed (0)
  7. internal/kms/conn.go

    	// MAC generates the checksum of the given req.Message using the key
    	// with the req.Name at the KMS.
    	MAC(context.Context, *MACRequest) ([]byte, error)
    }
    
    var ( // compiler checks
    	_ conn = (*kmsConn)(nil)
    	_ conn = (*kesConn)(nil)
    	_ conn = secretKey{}
    )
    
    // Supported KMS types
    const (
    	MinKMS  Type = iota + 1 // MinIO KMS
    	MinKES                  // MinIO MinKES
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue May 07 23:55:37 UTC 2024
    - 5K bytes
    - Viewed (0)
  8. pkg/test/loadbalancersim/loadbalancer/leastrequest.go

    	edfMutex          sync.Mutex
    }
    
    func newWeightedLeastRequest(conn *weightedConnections, activeRequestBias float64) network.Connection {
    	lb := &weightedLeastRequest{
    		weightedConnections: conn,
    		activeRequestBias:   activeRequestBias,
    		edf:                 NewEDF(),
    	}
    
    	// Add all endpoints to the EDF scheduler.
    	for _, c := range conn.conns {
    		lb.edf.Add(lb.calcEDFWeight(0, c), c)
    	}
    
    	return lb
    }
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Nov 14 20:23:34 UTC 2022
    - 3.4K bytes
    - Viewed (0)
  9. src/database/sql/sql_test.go

    	ctx := context.Background()
    
    	conn0, err := db.conn(ctx, cachedOrNewConn)
    	if err != nil {
    		t.Fatalf("db open conn fail: %v", err)
    	}
    
    	conn1, err := db.conn(ctx, cachedOrNewConn)
    	if err != nil {
    		t.Fatalf("db open conn fail: %v", err)
    	}
    
    	conn2, err := db.conn(ctx, cachedOrNewConn)
    	if err != nil {
    		t.Fatalf("db open conn fail: %v", err)
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 111.6K bytes
    - Viewed (0)
  10. pilot/pkg/autoregistration/connections.go

    	m.Lock()
    	defer m.Unlock()
    	var conns []connection
    	for key, connections := range m.byProxy {
    		if key.GroupName == wg.Name && key.Namespace == wg.Namespace {
    			conns = append(conns, maps.Values(connections)...)
    		}
    	}
    	return conns
    }
    
    func (m *adsConnections) Connect(conn connection) {
    	m.Lock()
    	defer m.Unlock()
    	k := makeProxyKey(conn.Proxy())
    
    	connections := m.byProxy[k]
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Sep 19 20:41:55 UTC 2023
    - 3K bytes
    - Viewed (0)
Back to top