• Tim Hockin's avatar
    Implement multi-port endpoints · 8ae20382
    Tim Hockin authored
    Instead of endpoints being a flat list, it is now a list of "subsets"
    where each is a struct of {Addresses, Ports}.  To generate the list of
    endpoints you need to take union of the Cartesian products of the
    subsets.  This is compact in the vast majority of cases, yet still
    represents named ports and corner cases (e.g. each pod has a different
    port number).
    
    This also stores subsets in a deterministic order (sorted by hash) to
    avoid spurious updates and comparison problems.
    
    This is a fully compatible change - old objects and clients will
    keepworking as long as they don't need the new functionality.
    
    This is the prep for multi-port Services, which will add API to produce
    endpoints in this new structure.
    8ae20382
etcd_helper_watch_test.go 18.9 KB