Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 130 for netutils (0.15 sec)

  1. pkg/proxy/ipvs/graceful_termination_test.go

    	}{
    		{
    			name: "graceful delete, no connections results in deleting the real server immediatetly",
    			vs: &utilipvs.VirtualServer{
    				Address:  netutils.ParseIPSloppy("1.1.1.1"),
    				Protocol: "tcp",
    				Port:     uint16(80),
    			},
    			rs: &utilipvs.RealServer{
    				Address:      netutils.ParseIPSloppy("10.0.0.1"),
    				Port:         uint16(80),
    				Weight:       100,
    				ActiveConn:   0,
    				InactiveConn: 0,
    			},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Dec 19 01:20:51 UTC 2023
    - 11K bytes
    - Viewed (0)
  2. pkg/proxy/ipvs/util/ipvs_test.go

    				Address: netutils.ParseIPSloppy("1.2.3.4"),
    				Port:    3080,
    			},
    			rsB: &RealServer{
    				Address: netutils.ParseIPSloppy("1.2.3.4"),
    				Port:    3080,
    			},
    			equal:  true,
    			reason: "All fields equal",
    		},
    		{
    			rsA: &RealServer{
    				Address: netutils.ParseIPSloppy("2012::beef"),
    				Port:    3080,
    			},
    			rsB: &RealServer{
    				Address: netutils.ParseIPSloppy("2012::beef"),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Dec 19 01:20:51 UTC 2023
    - 8K bytes
    - Viewed (0)
  3. pkg/controller/nodeipam/ipam/range_allocator_test.go

    					_, clusterCIDRv4, _ := netutils.ParseCIDRSloppy("127.123.234.0/8")
    					_, clusterCIDRv6, _ := netutils.ParseCIDRSloppy("ace:cab:deca::/84")
    					_, clusterCIDRv4_2, _ := netutils.ParseCIDRSloppy("10.0.0.0/8")
    					return []*net.IPNet{clusterCIDRv4, clusterCIDRv6, clusterCIDRv4_2}
    				}(),
    				ServiceCIDR: func() *net.IPNet {
    					_, serviceCIDR, _ := netutils.ParseCIDRSloppy("127.123.234.0/26")
    					return serviceCIDR
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 10:06:15 UTC 2024
    - 25.2K bytes
    - Viewed (0)
  4. pkg/registry/core/service/ipallocator/storage/storage_test.go

    	"k8s.io/kubernetes/pkg/registry/registrytest"
    	netutils "k8s.io/utils/net"
    )
    
    func newStorage(t *testing.T) (*etcd3testing.EtcdTestServer, ipallocator.Interface, allocator.Interface, storage.Interface, factory.DestroyFunc) {
    	etcdStorage, server := registrytest.NewEtcdStorage(t, "")
    	_, cidr, err := netutils.ParseCIDRSloppy("192.168.1.0/24")
    	if err != nil {
    		t.Fatal(err)
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Aug 24 09:23:05 UTC 2023
    - 5.9K bytes
    - Viewed (0)
  5. pkg/proxy/util/utils.go

    func convertToV1IPFamily(ipFamily netutils.IPFamily) v1.IPFamily {
    	switch ipFamily {
    	case netutils.IPv4:
    		return v1.IPv4Protocol
    	case netutils.IPv6:
    		return v1.IPv6Protocol
    	}
    
    	return v1.IPFamilyUnknown
    }
    
    // OtherIPFamily returns the other ip family
    func OtherIPFamily(ipFamily v1.IPFamily) v1.IPFamily {
    	if ipFamily == v1.IPv6Protocol {
    		return v1.IPv4Protocol
    	}
    
    	return v1.IPv6Protocol
    }
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon May 20 11:57:43 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  6. pkg/proxy/util/nodeport_addresses_test.go

    					addrs: []net.Addr{
    						&net.IPNet{IP: netutils.ParseIPSloppy("1.2.3.4"), Mask: net.CIDRMask(30, 32)},
    						&net.IPNet{IP: netutils.ParseIPSloppy("2001:db8::1"), Mask: net.CIDRMask(64, 128)},
    					},
    				},
    				{
    					itf: net.Interface{Index: 1, MTU: 0, Name: "lo", HardwareAddr: nil, Flags: 0},
    					addrs: []net.Addr{
    						&net.IPNet{IP: netutils.ParseIPSloppy("127.0.0.1"), Mask: net.CIDRMask(8, 32)},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 18 13:25:06 UTC 2024
    - 13.7K bytes
    - Viewed (0)
  7. pkg/proxy/ipvs/util/testing/fake_test.go

    	// Add a virtual server
    	vs := &utilipvs.VirtualServer{
    		Address:  netutils.ParseIPSloppy("10.20.30.40"),
    		Port:     uint16(80),
    		Protocol: string("TCP"),
    	}
    	rss := []*utilipvs.RealServer{
    		{Address: netutils.ParseIPSloppy("172.16.2.1"), Port: 8080, Weight: 1},
    		{Address: netutils.ParseIPSloppy("172.16.2.2"), Port: 8080, Weight: 2},
    		{Address: netutils.ParseIPSloppy("172.16.2.3"), Port: 8080, Weight: 3},
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Dec 19 01:20:51 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  8. pkg/registry/core/service/ipallocator/cidrallocator_test.go

    		allocator, err := r.getAllocator(netutils.ParseIPSloppy("10.0.0.11"))
    		if err != nil {
    			return false, nil
    		}
    		allocator.ipAddressSynced = func() bool { return true }
    		return allocator.ready.Load(), nil
    	})
    	if err != nil {
    		t.Fatal(err)
    	}
    	// allocate one IP from the new allocator
    	err = r.Allocate(netutils.ParseIPSloppy("10.0.0.11"))
    	if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Oct 31 21:05:06 UTC 2023
    - 13.7K bytes
    - Viewed (0)
  9. cmd/kube-apiserver/app/options/validation_test.go

    	_, ipv4cidr, err := netutils.ParseCIDRSloppy("192.168.0.0/24")
    	if err != nil {
    		t.Fatalf("Unexpected error %v", err)
    	}
    
    	_, ipv6cidr, err := netutils.ParseCIDRSloppy("2001:db8::/112")
    	if err != nil {
    		t.Fatalf("Unexpected error %v", err)
    	}
    
    	ipv4address := netutils.ParseIPSloppy("192.168.1.1")
    	ipv6address := netutils.ParseIPSloppy("2001:db8::1")
    
    	tests := []struct {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  10. pkg/registry/core/service/ipallocator/controller/repair_test.go

    	}
    }
    
    func TestRepairLeakDualStack(t *testing.T) {
    	clearMetrics()
    	_, cidr, _ := netutils.ParseCIDRSloppy("192.168.1.0/24")
    	previous, err := ipallocator.NewInMemory(cidr)
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	previous.Allocate(netutils.ParseIPSloppy("192.168.1.10"))
    
    	_, secondaryCIDR, _ := netutils.ParseCIDRSloppy("2000::/108")
    	secondaryPrevious, err := ipallocator.NewInMemory(secondaryCIDR)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Sep 30 15:46:06 UTC 2023
    - 21.1K bytes
    - Viewed (0)
Back to top