Merge pull request #44830 from NickrenREN/remove-NodeLegacyHostIP

Automatic merge from submit-queue

Remove deprecated NodeLegacyHostIP

**Release note**:
```release-note
Remove deprecated node address type `NodeLegacyHostIP`.
```

ref #44807
This commit is contained in:
Kubernetes Submit Queue
2017-05-05 15:38:58 -07:00
committed by GitHub
21 changed files with 31 additions and 88 deletions

View File

@@ -2918,16 +2918,12 @@ type NodeCondition struct {
type NodeAddressType string
// These are valid address types of node. NodeLegacyHostIP is used to transit
// from out-dated HostIP field to NodeAddress.
const (
// Deprecated: NodeLegacyHostIP will be removed in 1.7.
NodeLegacyHostIP NodeAddressType = "LegacyHostIP"
NodeHostName NodeAddressType = "Hostname"
NodeExternalIP NodeAddressType = "ExternalIP"
NodeInternalIP NodeAddressType = "InternalIP"
NodeExternalDNS NodeAddressType = "ExternalDNS"
NodeInternalDNS NodeAddressType = "InternalDNS"
NodeHostName NodeAddressType = "Hostname"
NodeExternalIP NodeAddressType = "ExternalIP"
NodeInternalIP NodeAddressType = "InternalIP"
NodeExternalDNS NodeAddressType = "ExternalDNS"
NodeInternalDNS NodeAddressType = "InternalDNS"
)
type NodeAddress struct {

View File

@@ -3363,13 +3363,11 @@ type NodeAddressType string
// These are valid address type of node.
const (
// Deprecated: NodeLegacyHostIP will be removed in 1.7.
NodeLegacyHostIP NodeAddressType = "LegacyHostIP"
NodeHostName NodeAddressType = "Hostname"
NodeExternalIP NodeAddressType = "ExternalIP"
NodeInternalIP NodeAddressType = "InternalIP"
NodeExternalDNS NodeAddressType = "ExternalDNS"
NodeInternalDNS NodeAddressType = "InternalDNS"
NodeHostName NodeAddressType = "Hostname"
NodeExternalIP NodeAddressType = "ExternalIP"
NodeInternalIP NodeAddressType = "InternalIP"
NodeExternalDNS NodeAddressType = "ExternalDNS"
NodeInternalDNS NodeAddressType = "InternalDNS"
)
// NodeAddress contains information for the node's address.

View File

@@ -6304,7 +6304,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6322,7 +6322,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6339,7 +6339,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6378,7 +6378,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6466,7 +6466,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6485,7 +6485,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6504,7 +6504,7 @@ func TestValidateNode(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "something"},
{Type: api.NodeExternalIP, Address: "something"},
},
Capacity: api.ResourceList{
api.ResourceName(api.ResourceCPU): resource.MustParse("10"),
@@ -6747,7 +6747,7 @@ func TestValidateNodeUpdate(t *testing.T) {
},
Status: api.NodeStatus{
Addresses: []api.NodeAddress{
{Type: api.NodeLegacyHostIP, Address: "1.2.3.4"},
{Type: api.NodeExternalIP, Address: "1.2.3.4"},
},
},
}, api.Node{