Skip to content

Commit 94a3c50

Browse files
1 parent b0ad259 commit 94a3c50

File tree

7 files changed

+315
-6
lines changed

7 files changed

+315
-6
lines changed

src/NetworkManagement/AbortInfo.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,12 @@ class AbortInfo extends \Google\Collection
219219
* Aborted because the used protocol is not supported for the used IP version.
220220
*/
221221
public const CAUSE_IP_VERSION_PROTOCOL_MISMATCH = 'IP_VERSION_PROTOCOL_MISMATCH';
222+
/**
223+
* Aborted because selected GKE Pod endpoint location is unknown. This is
224+
* often the case for "Pending" Pods, which don't have assigned IP addresses
225+
* yet.
226+
*/
227+
public const CAUSE_GKE_POD_UNKNOWN_ENDPOINT_LOCATION = 'GKE_POD_UNKNOWN_ENDPOINT_LOCATION';
222228
protected $collection_key = 'projectsMissingPermission';
223229
/**
224230
* Causes that the analysis is aborted.
@@ -267,7 +273,7 @@ class AbortInfo extends \Google\Collection
267273
* SOURCE_REDIS_INSTANCE_UNSUPPORTED, SOURCE_FORWARDING_RULE_UNSUPPORTED,
268274
* NON_ROUTABLE_IP_ADDRESS, UNKNOWN_ISSUE_IN_GOOGLE_MANAGED_PROJECT,
269275
* UNSUPPORTED_GOOGLE_MANAGED_PROJECT_CONFIG, NO_SERVERLESS_IP_RANGES,
270-
* IP_VERSION_PROTOCOL_MISMATCH
276+
* IP_VERSION_PROTOCOL_MISMATCH, GKE_POD_UNKNOWN_ENDPOINT_LOCATION
271277
*
272278
* @param self::CAUSE_* $cause
273279
*/

src/NetworkManagement/DeliverInfo.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,10 @@ class DeliverInfo extends \Google\Model
130130
* Target is a Redis Cluster.
131131
*/
132132
public const TARGET_REDIS_CLUSTER = 'REDIS_CLUSTER';
133+
/**
134+
* Target is a GKE Pod.
135+
*/
136+
public const TARGET_GKE_POD = 'GKE_POD';
133137
/**
134138
* Recognized type of a Google Service the packet is delivered to (if
135139
* applicable).
@@ -262,7 +266,7 @@ public function getStorageBucket()
262266
* GKE_MASTER, CLOUD_SQL_INSTANCE, PSC_PUBLISHED_SERVICE, PSC_GOOGLE_API,
263267
* PSC_VPC_SC, SERVERLESS_NEG, STORAGE_BUCKET, PRIVATE_NETWORK,
264268
* CLOUD_FUNCTION, APP_ENGINE_VERSION, CLOUD_RUN_REVISION,
265-
* GOOGLE_MANAGED_SERVICE, REDIS_INSTANCE, REDIS_CLUSTER
269+
* GOOGLE_MANAGED_SERVICE, REDIS_INSTANCE, REDIS_CLUSTER, GKE_POD
266270
*
267271
* @param self::TARGET_* $target
268272
*/

src/NetworkManagement/DropInfo.php

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,10 @@ class DropInfo extends \Google\Model
158158
* Packet sent from or to a GKE cluster that is not in running state.
159159
*/
160160
public const CAUSE_GKE_CLUSTER_NOT_RUNNING = 'GKE_CLUSTER_NOT_RUNNING';
161+
/**
162+
* Packet sent from or to a GKE Pod that is not in running state.
163+
*/
164+
public const CAUSE_GKE_POD_NOT_RUNNING = 'GKE_POD_NOT_RUNNING';
161165
/**
162166
* Packet sent from or to a Cloud SQL instance that is not in running state.
163167
*/
@@ -469,6 +473,11 @@ class DropInfo extends \Google\Model
469473
* dropped due to no matching NAT gateway in the subnet.
470474
*/
471475
public const CAUSE_NO_MATCHING_NAT64_GATEWAY = 'NO_MATCHING_NAT64_GATEWAY';
476+
/**
477+
* Packet is dropped due to matching a Private NAT64 gateway with no rules for
478+
* source IPv6 addresses.
479+
*/
480+
public const CAUSE_NO_CONFIGURED_PRIVATE_NAT64_RULE = 'NO_CONFIGURED_PRIVATE_NAT64_RULE';
472481
/**
473482
* Packet is dropped due to being sent to a backend of a passthrough load
474483
* balancer that doesn't use the same IP version as the frontend.
@@ -576,7 +585,7 @@ class DropInfo extends \Google\Model
576585
* FORWARDING_RULE_NO_INSTANCES,
577586
* FIREWALL_BLOCKING_LOAD_BALANCER_BACKEND_HEALTH_CHECK,
578587
* INGRESS_FIREWALL_TAGS_UNSUPPORTED_BY_DIRECT_VPC_EGRESS,
579-
* INSTANCE_NOT_RUNNING, GKE_CLUSTER_NOT_RUNNING,
588+
* INSTANCE_NOT_RUNNING, GKE_CLUSTER_NOT_RUNNING, GKE_POD_NOT_RUNNING,
580589
* CLOUD_SQL_INSTANCE_NOT_RUNNING, REDIS_INSTANCE_NOT_RUNNING,
581590
* REDIS_CLUSTER_NOT_RUNNING, TRAFFIC_TYPE_BLOCKED,
582591
* GKE_MASTER_UNAUTHORIZED_ACCESS, CLOUD_SQL_INSTANCE_UNAUTHORIZED_ACCESS,
@@ -618,7 +627,8 @@ class DropInfo extends \Google\Model
618627
* PSC_PORT_MAPPING_WITHOUT_PSC_CONNECTION_UNSUPPORTED,
619628
* UNSUPPORTED_ROUTE_MATCHED_FOR_NAT64_DESTINATION,
620629
* TRAFFIC_FROM_HYBRID_ENDPOINT_TO_INTERNET_DISALLOWED,
621-
* NO_MATCHING_NAT64_GATEWAY, LOAD_BALANCER_BACKEND_IP_VERSION_MISMATCH,
630+
* NO_MATCHING_NAT64_GATEWAY, NO_CONFIGURED_PRIVATE_NAT64_RULE,
631+
* LOAD_BALANCER_BACKEND_IP_VERSION_MISMATCH,
622632
* NO_KNOWN_ROUTE_FROM_NCC_NETWORK_TO_DESTINATION,
623633
* CLOUD_NAT_PROTOCOL_UNSUPPORTED, L2_INTERCONNECT_UNSUPPORTED_PROTOCOL,
624634
* L2_INTERCONNECT_UNSUPPORTED_PORT, L2_INTERCONNECT_DESTINATION_IP_MISMATCH,

src/NetworkManagement/Endpoint.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,13 @@ class Endpoint extends \Google\Model
147147
* @var string
148148
*/
149149
public $gkeMasterCluster;
150+
/**
151+
* A [GKE Pod](https://cloud.google.com/kubernetes-engine/docs/concepts/pod)
152+
* URI.
153+
*
154+
* @var string
155+
*/
156+
public $gkePod;
150157
/**
151158
* A Compute Engine instance URI.
152159
*
@@ -369,6 +376,23 @@ public function getGkeMasterCluster()
369376
{
370377
return $this->gkeMasterCluster;
371378
}
379+
/**
380+
* A [GKE Pod](https://cloud.google.com/kubernetes-engine/docs/concepts/pod)
381+
* URI.
382+
*
383+
* @param string $gkePod
384+
*/
385+
public function setGkePod($gkePod)
386+
{
387+
$this->gkePod = $gkePod;
388+
}
389+
/**
390+
* @return string
391+
*/
392+
public function getGkePod()
393+
{
394+
return $this->gkePod;
395+
}
372396
/**
373397
* A Compute Engine instance URI.
374398
*
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\NetworkManagement;
19+
20+
class GkePodInfo extends \Google\Model
21+
{
22+
/**
23+
* IP address of a GKE Pod. If the Pod is dual-stack, this is the IP address
24+
* relevant to the trace.
25+
*
26+
* @var string
27+
*/
28+
public $ipAddress;
29+
/**
30+
* URI of the network containing the GKE Pod.
31+
*
32+
* @var string
33+
*/
34+
public $networkUri;
35+
/**
36+
* URI of a GKE Pod. For Pods in regional Clusters, the URI format is: `projec
37+
* ts/{project}/locations/{location}/clusters/{cluster}/k8s/namespaces/{namesp
38+
* ace}/pods/{pod}` For Pods in zonal Clusters, the URI format is: `projects/{
39+
* project}/zones/{zone}/clusters/{cluster}/k8s/namespaces/{namespace}/pods/{p
40+
* od}`
41+
*
42+
* @var string
43+
*/
44+
public $podUri;
45+
46+
/**
47+
* IP address of a GKE Pod. If the Pod is dual-stack, this is the IP address
48+
* relevant to the trace.
49+
*
50+
* @param string $ipAddress
51+
*/
52+
public function setIpAddress($ipAddress)
53+
{
54+
$this->ipAddress = $ipAddress;
55+
}
56+
/**
57+
* @return string
58+
*/
59+
public function getIpAddress()
60+
{
61+
return $this->ipAddress;
62+
}
63+
/**
64+
* URI of the network containing the GKE Pod.
65+
*
66+
* @param string $networkUri
67+
*/
68+
public function setNetworkUri($networkUri)
69+
{
70+
$this->networkUri = $networkUri;
71+
}
72+
/**
73+
* @return string
74+
*/
75+
public function getNetworkUri()
76+
{
77+
return $this->networkUri;
78+
}
79+
/**
80+
* URI of a GKE Pod. For Pods in regional Clusters, the URI format is: `projec
81+
* ts/{project}/locations/{location}/clusters/{cluster}/k8s/namespaces/{namesp
82+
* ace}/pods/{pod}` For Pods in zonal Clusters, the URI format is: `projects/{
83+
* project}/zones/{zone}/clusters/{cluster}/k8s/namespaces/{namespace}/pods/{p
84+
* od}`
85+
*
86+
* @param string $podUri
87+
*/
88+
public function setPodUri($podUri)
89+
{
90+
$this->podUri = $podUri;
91+
}
92+
/**
93+
* @return string
94+
*/
95+
public function getPodUri()
96+
{
97+
return $this->podUri;
98+
}
99+
}
100+
101+
// Adding a class alias for backwards compatibility with the previous class name.
102+
class_alias(GkePodInfo::class, 'Google_Service_NetworkManagement_GkePodInfo');
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\NetworkManagement;
19+
20+
class IpMasqueradingSkippedInfo extends \Google\Model
21+
{
22+
/**
23+
* Unused default value.
24+
*/
25+
public const REASON_REASON_UNSPECIFIED = 'REASON_UNSPECIFIED';
26+
/**
27+
* Masquerading not applied because destination IP is in one of configured
28+
* non-masquerade ranges.
29+
*/
30+
public const REASON_DESTINATION_IP_IN_CONFIGURED_NON_MASQUERADE_RANGE = 'DESTINATION_IP_IN_CONFIGURED_NON_MASQUERADE_RANGE';
31+
/**
32+
* Masquerading not applied because destination IP is in one of default non-
33+
* masquerade ranges.
34+
*/
35+
public const REASON_DESTINATION_IP_IN_DEFAULT_NON_MASQUERADE_RANGE = 'DESTINATION_IP_IN_DEFAULT_NON_MASQUERADE_RANGE';
36+
/**
37+
* Masquerading not applied because destination is on the same Node.
38+
*/
39+
public const REASON_DESTINATION_ON_SAME_NODE = 'DESTINATION_ON_SAME_NODE';
40+
/**
41+
* Masquerading not applied because ip-masq-agent doesn't exist and default
42+
* SNAT is disabled.
43+
*/
44+
public const REASON_DEFAULT_SNAT_DISABLED = 'DEFAULT_SNAT_DISABLED';
45+
/**
46+
* Masquerading not applied because the packet's IP version is IPv6.
47+
*/
48+
public const REASON_NO_MASQUERADING_FOR_IPV6 = 'NO_MASQUERADING_FOR_IPV6';
49+
/**
50+
* Masquerading not applied because the source Pod uses the host Node's
51+
* network namespace, including the Node's IP address.
52+
*/
53+
public const REASON_POD_USES_NODE_NETWORK_NAMESPACE = 'POD_USES_NODE_NETWORK_NAMESPACE';
54+
/**
55+
* Masquerading not applied because the packet is a return packet.
56+
*/
57+
public const REASON_NO_MASQUERADING_FOR_RETURN_PACKET = 'NO_MASQUERADING_FOR_RETURN_PACKET';
58+
/**
59+
* The matched non-masquerade IP range. Only set if reason is
60+
* DESTINATION_IP_IN_CONFIGURED_NON_MASQUERADE_RANGE or
61+
* DESTINATION_IP_IN_DEFAULT_NON_MASQUERADE_RANGE.
62+
*
63+
* @var string
64+
*/
65+
public $nonMasqueradeRange;
66+
/**
67+
* Reason why IP masquerading was not applied.
68+
*
69+
* @var string
70+
*/
71+
public $reason;
72+
73+
/**
74+
* The matched non-masquerade IP range. Only set if reason is
75+
* DESTINATION_IP_IN_CONFIGURED_NON_MASQUERADE_RANGE or
76+
* DESTINATION_IP_IN_DEFAULT_NON_MASQUERADE_RANGE.
77+
*
78+
* @param string $nonMasqueradeRange
79+
*/
80+
public function setNonMasqueradeRange($nonMasqueradeRange)
81+
{
82+
$this->nonMasqueradeRange = $nonMasqueradeRange;
83+
}
84+
/**
85+
* @return string
86+
*/
87+
public function getNonMasqueradeRange()
88+
{
89+
return $this->nonMasqueradeRange;
90+
}
91+
/**
92+
* Reason why IP masquerading was not applied.
93+
*
94+
* Accepted values: REASON_UNSPECIFIED,
95+
* DESTINATION_IP_IN_CONFIGURED_NON_MASQUERADE_RANGE,
96+
* DESTINATION_IP_IN_DEFAULT_NON_MASQUERADE_RANGE, DESTINATION_ON_SAME_NODE,
97+
* DEFAULT_SNAT_DISABLED, NO_MASQUERADING_FOR_IPV6,
98+
* POD_USES_NODE_NETWORK_NAMESPACE, NO_MASQUERADING_FOR_RETURN_PACKET
99+
*
100+
* @param self::REASON_* $reason
101+
*/
102+
public function setReason($reason)
103+
{
104+
$this->reason = $reason;
105+
}
106+
/**
107+
* @return self::REASON_*
108+
*/
109+
public function getReason()
110+
{
111+
return $this->reason;
112+
}
113+
}
114+
115+
// Adding a class alias for backwards compatibility with the previous class name.
116+
class_alias(IpMasqueradingSkippedInfo::class, 'Google_Service_NetworkManagement_IpMasqueradingSkippedInfo');

0 commit comments

Comments
 (0)