Chapter 38. NetworkPolicyService
38.1. GetAllowedPeersFromCurrentPolicyForDeployment Copy linkLink copied to clipboard!
GET /v1/networkpolicies/allowedpeers/{id}
38.1.1. Description Copy linkLink copied to clipboard!
38.1.2. Parameters Copy linkLink copied to clipboard!
38.1.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| id | X | null |
38.1.3. Return Type Copy linkLink copied to clipboard!
38.1.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.1.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.1.6. Samples Copy linkLink copied to clipboard!
38.1.7. Common object reference Copy linkLink copied to clipboard!
38.1.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.1.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.1.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.1.7.3. StorageL4Protocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| L4_PROTOCOL_UNKNOWN |
| L4_PROTOCOL_TCP |
| L4_PROTOCOL_UDP |
| L4_PROTOCOL_ICMP |
| L4_PROTOCOL_RAW |
| L4_PROTOCOL_SCTP |
| L4_PROTOCOL_ANY |
38.1.7.4. StorageNetworkEntityInfoType Copy linkLink copied to clipboard!
- INTERNAL_ENTITIES: INTERNAL_ENTITIES is for grouping all internal entities under a single network graph node
| Enum Values |
|---|
| UNKNOWN_TYPE |
| DEPLOYMENT |
| INTERNET |
| LISTEN_ENDPOINT |
| EXTERNAL_SOURCE |
| INTERNAL_ENTITIES |
38.1.7.5. V1GetAllowedPeersFromCurrentPolicyForDeploymentResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| allowedPeers | List of V1NetworkBaselineStatusPeer |
38.1.7.6. V1NetworkBaselinePeerEntity Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| id | String | ||||
| type | UNKNOWN_TYPE, DEPLOYMENT, INTERNET, LISTEN_ENDPOINT, EXTERNAL_SOURCE, INTERNAL_ENTITIES, |
38.1.7.7. V1NetworkBaselineStatusPeer Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| port | Long | The port and protocol of the destination of the given connection. | int64 | ||
| protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, | ||||
| ingress | Boolean | A boolean representing whether the query is for an ingress or egress connection. This is defined with respect to the current deployment. Thus: - If the connection in question is in the outEdges of the current deployment, this should be false. - If it is in the outEdges of the peer deployment, this should be true. |
38.2. ApplyNetworkPolicy Copy linkLink copied to clipboard!
POST /v1/networkpolicies/apply/{clusterId}
38.2.1. Description Copy linkLink copied to clipboard!
38.2.2. Parameters Copy linkLink copied to clipboard!
38.2.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.2.2.2. Body Parameter Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| body | X |
38.2.3. Return Type Copy linkLink copied to clipboard!
Object
38.2.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.2.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. |
|
| 0 | An unexpected error response. |
38.2.6. Samples Copy linkLink copied to clipboard!
38.2.7. Common object reference Copy linkLink copied to clipboard!
38.2.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.2.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.2.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.2.7.3. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.2.7.4. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.3. ApplyNetworkPolicyYamlForDeployment Copy linkLink copied to clipboard!
POST /v1/networkpolicies/apply/deployment/{deploymentId}
38.3.1. Description Copy linkLink copied to clipboard!
38.3.2. Parameters Copy linkLink copied to clipboard!
38.3.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| deploymentId | X | null |
38.3.2.2. Body Parameter Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| body | X |
38.3.3. Return Type Copy linkLink copied to clipboard!
Object
38.3.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.3.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. |
|
| 0 | An unexpected error response. |
38.3.6. Samples Copy linkLink copied to clipboard!
38.3.7. Common object reference Copy linkLink copied to clipboard!
38.3.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.3.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.3.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.3.7.3. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.3.7.4. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.3.7.5. V1ApplyNetworkPolicyYamlForDeploymentRequest Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| deploymentId | String | ||||
| modification |
38.4. GetDiffFlowsBetweenPolicyAndBaselineForDeployment Copy linkLink copied to clipboard!
GET /v1/networkpolicies/baselinecomparison/{id}
38.4.1. Description Copy linkLink copied to clipboard!
38.4.2. Parameters Copy linkLink copied to clipboard!
38.4.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| id | X | null |
38.4.3. Return Type Copy linkLink copied to clipboard!
38.4.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.4.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.4.6. Samples Copy linkLink copied to clipboard!
38.4.7. Common object reference Copy linkLink copied to clipboard!
38.4.7.1. DeploymentListenPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| l4protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.4.7.2. NetworkEntityInfoExternalSource Copy linkLink copied to clipboard!
Update normalizeDupNameExtSrcs(…) in central/networkgraph/aggregator/aggregator.go whenever this message is updated.
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| cidr | String | ||||
| default | Boolean |
|
38.4.7.3. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.4.7.3.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.4.7.4. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.4.7.5. StorageL4Protocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| L4_PROTOCOL_UNKNOWN |
| L4_PROTOCOL_TCP |
| L4_PROTOCOL_UDP |
| L4_PROTOCOL_ICMP |
| L4_PROTOCOL_RAW |
| L4_PROTOCOL_SCTP |
| L4_PROTOCOL_ANY |
38.4.7.6. StorageNetworkBaselineConnectionProperties Copy linkLink copied to clipboard!
NetworkBaselineConnectionProperties represents information about a baseline connection next available tag: 4
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ingress | Boolean | ||||
| port | Long | int64 | |||
| protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.4.7.7. StorageNetworkEntityInfo Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| type | UNKNOWN_TYPE, DEPLOYMENT, INTERNET, LISTEN_ENDPOINT, EXTERNAL_SOURCE, INTERNAL_ENTITIES, | ||||
| id | String | ||||
| deployment | |||||
| externalSource |
38.4.7.8. StorageNetworkEntityInfoDeployment Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| namespace | String | ||||
| cluster | String | ||||
| listenPorts | List of DeploymentListenPort |
38.4.7.9. StorageNetworkEntityInfoType Copy linkLink copied to clipboard!
- INTERNAL_ENTITIES: INTERNAL_ENTITIES is for grouping all internal entities under a single network graph node
| Enum Values |
|---|
| UNKNOWN_TYPE |
| DEPLOYMENT |
| INTERNET |
| LISTEN_ENDPOINT |
| EXTERNAL_SOURCE |
| INTERNAL_ENTITIES |
38.4.7.10. V1GetDiffFlowsGroupedFlow Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| properties |
38.4.7.11. V1GetDiffFlowsReconciledFlow Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| added | |||||
| removed | |||||
| unchanged |
38.4.7.12. V1GetDiffFlowsResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| added | List of V1GetDiffFlowsGroupedFlow | ||||
| removed | List of V1GetDiffFlowsGroupedFlow | ||||
| reconciled | List of V1GetDiffFlowsReconciledFlow |
38.5. GetNetworkGraph Copy linkLink copied to clipboard!
GET /v1/networkpolicies/cluster/{clusterId}
38.5.1. Description Copy linkLink copied to clipboard!
38.5.2. Parameters Copy linkLink copied to clipboard!
38.5.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.5.2.2. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| query | - | null | ||
| includePorts | If set to true, include port-level information in the network policy graph. | - | null | |
| scope.query | - | null |
38.5.3. Return Type Copy linkLink copied to clipboard!
38.5.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.5.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.5.6. Samples Copy linkLink copied to clipboard!
38.5.7. Common object reference Copy linkLink copied to clipboard!
38.5.7.1. DeploymentListenPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| l4protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.5.7.2. NetworkEntityInfoExternalSource Copy linkLink copied to clipboard!
Update normalizeDupNameExtSrcs(…) in central/networkgraph/aggregator/aggregator.go whenever this message is updated.
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| cidr | String | ||||
| default | Boolean |
|
38.5.7.3. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.5.7.3.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.5.7.4. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.5.7.5. StorageL4Protocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| L4_PROTOCOL_UNKNOWN |
| L4_PROTOCOL_TCP |
| L4_PROTOCOL_UDP |
| L4_PROTOCOL_ICMP |
| L4_PROTOCOL_RAW |
| L4_PROTOCOL_SCTP |
| L4_PROTOCOL_ANY |
38.5.7.6. StorageNetworkEntityInfo Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| type | UNKNOWN_TYPE, DEPLOYMENT, INTERNET, LISTEN_ENDPOINT, EXTERNAL_SOURCE, INTERNAL_ENTITIES, | ||||
| id | String | ||||
| deployment | |||||
| externalSource |
38.5.7.7. StorageNetworkEntityInfoDeployment Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| namespace | String | ||||
| cluster | String | ||||
| listenPorts | List of DeploymentListenPort |
38.5.7.8. StorageNetworkEntityInfoType Copy linkLink copied to clipboard!
- INTERNAL_ENTITIES: INTERNAL_ENTITIES is for grouping all internal entities under a single network graph node
| Enum Values |
|---|
| UNKNOWN_TYPE |
| DEPLOYMENT |
| INTERNET |
| LISTEN_ENDPOINT |
| EXTERNAL_SOURCE |
| INTERNAL_ENTITIES |
38.5.7.9. V1NetworkEdgeProperties Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, | ||||
| lastActiveTimestamp | Date | date-time |
38.5.7.10. V1NetworkEdgePropertiesBundle Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| properties | List of V1NetworkEdgeProperties |
38.5.7.11. V1NetworkGraph Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| epoch | Long | int64 | |||
| nodes | List of V1NetworkNode |
38.5.7.12. V1NetworkNode Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| internetAccess | Boolean | ||||
| policyIds |
List of | ||||
| nonIsolatedIngress | Boolean | ||||
| nonIsolatedEgress | Boolean | ||||
| queryMatch | Boolean | ||||
| outEdges |
38.6. GetBaselineGeneratedNetworkPolicyForDeployment Copy linkLink copied to clipboard!
POST /v1/networkpolicies/generate/baseline/{deploymentId}
38.6.1. Description Copy linkLink copied to clipboard!
38.6.2. Parameters Copy linkLink copied to clipboard!
38.6.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| deploymentId | X | null |
38.6.2.2. Body Parameter Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| body | X |
38.6.3. Return Type Copy linkLink copied to clipboard!
38.6.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.6.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.6.6. Samples Copy linkLink copied to clipboard!
38.6.7. Common object reference Copy linkLink copied to clipboard!
38.6.7.1. GenerateNetworkPoliciesRequestDeleteExistingPoliciesMode Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNKNOWN |
| NONE |
| GENERATED_ONLY |
| ALL |
38.6.7.2. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.6.7.2.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.6.7.3. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.6.7.4. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.6.7.5. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.6.7.6. V1GetBaselineGeneratedPolicyForDeploymentRequest Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| deploymentId | String | ||||
| deleteExisting | UNKNOWN, NONE, GENERATED_ONLY, ALL, | ||||
| includePorts | Boolean |
38.6.7.7. V1GetBaselineGeneratedPolicyForDeploymentResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| modification |
38.7. GenerateNetworkPolicies Copy linkLink copied to clipboard!
GET /v1/networkpolicies/generate/{clusterId}
38.7.1. Description Copy linkLink copied to clipboard!
38.7.2. Parameters Copy linkLink copied to clipboard!
38.7.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.7.2.2. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| query | - | null | ||
| deleteExisting | - | UNKNOWN | ||
| networkDataSince | - | null | ||
| includePorts | - | null |
38.7.3. Return Type Copy linkLink copied to clipboard!
38.7.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.7.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.7.6. Samples Copy linkLink copied to clipboard!
38.7.7. Common object reference Copy linkLink copied to clipboard!
38.7.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.7.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.7.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.7.7.3. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.7.7.4. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.7.7.5. V1GenerateNetworkPoliciesResponse Copy linkLink copied to clipboard!
Next available tag: 2
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| modification |
38.8. GetNetworkPolicies Copy linkLink copied to clipboard!
GET /v1/networkpolicies
38.8.1. Description Copy linkLink copied to clipboard!
38.8.2. Parameters Copy linkLink copied to clipboard!
38.8.2.1. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | - | null | ||
| deploymentQuery | - | null | ||
| namespace | - | null |
38.8.3. Return Type Copy linkLink copied to clipboard!
38.8.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.8.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.8.6. Samples Copy linkLink copied to clipboard!
38.8.7. Common object reference Copy linkLink copied to clipboard!
38.8.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.8.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.8.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.8.7.3. StorageIPBlock Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| cidr | String | ||||
| except |
List of |
38.8.7.4. StorageLabelSelector Copy linkLink copied to clipboard!
Label selector components are joined with logical AND, see https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| matchLabels |
Map of | This is actually a oneof, but we can’t make it one due to backwards compatibility constraints. | |||
| requirements | List of StorageLabelSelectorRequirement |
38.8.7.5. StorageLabelSelectorOperator Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNKNOWN |
| IN |
| NOT_IN |
| EXISTS |
| NOT_EXISTS |
38.8.7.6. StorageLabelSelectorRequirement Copy linkLink copied to clipboard!
Next available tag: 4
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| key | String | ||||
| op | UNKNOWN, IN, NOT_IN, EXISTS, NOT_EXISTS, | ||||
| values |
List of |
38.8.7.7. StorageNetworkPolicy Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| id | String | ||||
| name | String | ||||
| clusterId | String | ||||
| clusterName | String | ||||
| namespace | String | ||||
| labels |
Map of | ||||
| annotations |
Map of | ||||
| spec | |||||
| yaml | String | ||||
| apiVersion | String | ||||
| created | Date | date-time |
38.8.7.8. StorageNetworkPolicyEgressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| to | List of StorageNetworkPolicyPeer |
38.8.7.9. StorageNetworkPolicyIngressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| from | List of StorageNetworkPolicyPeer |
38.8.7.10. StorageNetworkPolicyPeer Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| namespaceSelector | |||||
| ipBlock |
38.8.7.11. StorageNetworkPolicyPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| protocol | UNSET_PROTOCOL, TCP_PROTOCOL, UDP_PROTOCOL, SCTP_PROTOCOL, | ||||
| port | Integer | int32 | |||
| portName | String |
38.8.7.12. StorageNetworkPolicySpec Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| ingress | List of StorageNetworkPolicyIngressRule | ||||
| egress | List of StorageNetworkPolicyEgressRule | ||||
| policyTypes | List of StorageNetworkPolicyType |
38.8.7.13. StorageNetworkPolicyType Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_NETWORK_POLICY_TYPE |
| INGRESS_NETWORK_POLICY_TYPE |
| EGRESS_NETWORK_POLICY_TYPE |
38.8.7.14. StorageProtocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_PROTOCOL |
| TCP_PROTOCOL |
| UDP_PROTOCOL |
| SCTP_PROTOCOL |
38.8.7.15. V1NetworkPoliciesResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| networkPolicies | List of StorageNetworkPolicy |
38.9. GetNetworkGraphEpoch Copy linkLink copied to clipboard!
GET /v1/networkpolicies/graph/epoch
38.9.1. Description Copy linkLink copied to clipboard!
38.9.2. Parameters Copy linkLink copied to clipboard!
38.9.2.1. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | - | null |
38.9.3. Return Type Copy linkLink copied to clipboard!
38.9.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.9.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.9.6. Samples Copy linkLink copied to clipboard!
38.9.7. Common object reference Copy linkLink copied to clipboard!
38.9.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.9.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.9.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.9.7.3. V1NetworkGraphEpoch Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| epoch | Long | int64 |
38.10. GetNetworkPolicy Copy linkLink copied to clipboard!
GET /v1/networkpolicies/{id}
38.10.1. Description Copy linkLink copied to clipboard!
38.10.2. Parameters Copy linkLink copied to clipboard!
38.10.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| id | X | null |
38.10.3. Return Type Copy linkLink copied to clipboard!
38.10.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.10.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.10.6. Samples Copy linkLink copied to clipboard!
38.10.7. Common object reference Copy linkLink copied to clipboard!
38.10.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.10.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.10.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.10.7.3. StorageIPBlock Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| cidr | String | ||||
| except |
List of |
38.10.7.4. StorageLabelSelector Copy linkLink copied to clipboard!
Label selector components are joined with logical AND, see https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| matchLabels |
Map of | This is actually a oneof, but we can’t make it one due to backwards compatibility constraints. | |||
| requirements | List of StorageLabelSelectorRequirement |
38.10.7.5. StorageLabelSelectorOperator Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNKNOWN |
| IN |
| NOT_IN |
| EXISTS |
| NOT_EXISTS |
38.10.7.6. StorageLabelSelectorRequirement Copy linkLink copied to clipboard!
Next available tag: 4
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| key | String | ||||
| op | UNKNOWN, IN, NOT_IN, EXISTS, NOT_EXISTS, | ||||
| values |
List of |
38.10.7.7. StorageNetworkPolicy Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| id | String | ||||
| name | String | ||||
| clusterId | String | ||||
| clusterName | String | ||||
| namespace | String | ||||
| labels |
Map of | ||||
| annotations |
Map of | ||||
| spec | |||||
| yaml | String | ||||
| apiVersion | String | ||||
| created | Date | date-time |
38.10.7.8. StorageNetworkPolicyEgressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| to | List of StorageNetworkPolicyPeer |
38.10.7.9. StorageNetworkPolicyIngressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| from | List of StorageNetworkPolicyPeer |
38.10.7.10. StorageNetworkPolicyPeer Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| namespaceSelector | |||||
| ipBlock |
38.10.7.11. StorageNetworkPolicyPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| protocol | UNSET_PROTOCOL, TCP_PROTOCOL, UDP_PROTOCOL, SCTP_PROTOCOL, | ||||
| port | Integer | int32 | |||
| portName | String |
38.10.7.12. StorageNetworkPolicySpec Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| ingress | List of StorageNetworkPolicyIngressRule | ||||
| egress | List of StorageNetworkPolicyEgressRule | ||||
| policyTypes | List of StorageNetworkPolicyType |
38.10.7.13. StorageNetworkPolicyType Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_NETWORK_POLICY_TYPE |
| INGRESS_NETWORK_POLICY_TYPE |
| EGRESS_NETWORK_POLICY_TYPE |
38.10.7.14. StorageProtocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_PROTOCOL |
| TCP_PROTOCOL |
| UDP_PROTOCOL |
| SCTP_PROTOCOL |
38.11. SendNetworkPolicyYAML Copy linkLink copied to clipboard!
POST /v1/networkpolicies/simulate/{clusterId}/notify
38.11.1. Description Copy linkLink copied to clipboard!
38.11.2. Parameters Copy linkLink copied to clipboard!
38.11.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.11.2.2. Body Parameter Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| body | X |
38.11.2.3. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| notifierIds |
| - | null |
38.11.3. Return Type Copy linkLink copied to clipboard!
Object
38.11.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.11.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. |
|
| 0 | An unexpected error response. |
38.11.6. Samples Copy linkLink copied to clipboard!
38.11.7. Common object reference Copy linkLink copied to clipboard!
38.11.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.11.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.11.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.11.7.3. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.11.7.4. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.12. SimulateNetworkGraph Copy linkLink copied to clipboard!
POST /v1/networkpolicies/simulate/{clusterId}
38.12.1. Description Copy linkLink copied to clipboard!
38.12.2. Parameters Copy linkLink copied to clipboard!
38.12.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.12.2.2. Body Parameter Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| body | X |
38.12.2.3. Query Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| query | - | null | ||
| includePorts | If set to true, include port-level information in the network policy graph. | - | null | |
| includeNodeDiff | - | null | ||
| scope.query | - | null |
38.12.3. Return Type Copy linkLink copied to clipboard!
38.12.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.12.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.12.6. Samples Copy linkLink copied to clipboard!
38.12.7. Common object reference Copy linkLink copied to clipboard!
38.12.7.1. DeploymentListenPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| l4protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.12.7.2. NetworkEntityInfoExternalSource Copy linkLink copied to clipboard!
Update normalizeDupNameExtSrcs(…) in central/networkgraph/aggregator/aggregator.go whenever this message is updated.
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| cidr | String | ||||
| default | Boolean |
|
38.12.7.3. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.12.7.3.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.12.7.4. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.12.7.5. StorageIPBlock Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| cidr | String | ||||
| except |
List of |
38.12.7.6. StorageL4Protocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| L4_PROTOCOL_UNKNOWN |
| L4_PROTOCOL_TCP |
| L4_PROTOCOL_UDP |
| L4_PROTOCOL_ICMP |
| L4_PROTOCOL_RAW |
| L4_PROTOCOL_SCTP |
| L4_PROTOCOL_ANY |
38.12.7.7. StorageLabelSelector Copy linkLink copied to clipboard!
Label selector components are joined with logical AND, see https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| matchLabels |
Map of | This is actually a oneof, but we can’t make it one due to backwards compatibility constraints. | |||
| requirements | List of StorageLabelSelectorRequirement |
38.12.7.8. StorageLabelSelectorOperator Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNKNOWN |
| IN |
| NOT_IN |
| EXISTS |
| NOT_EXISTS |
38.12.7.9. StorageLabelSelectorRequirement Copy linkLink copied to clipboard!
Next available tag: 4
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| key | String | ||||
| op | UNKNOWN, IN, NOT_IN, EXISTS, NOT_EXISTS, | ||||
| values |
List of |
38.12.7.10. StorageNetworkEntityInfo Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| type | UNKNOWN_TYPE, DEPLOYMENT, INTERNET, LISTEN_ENDPOINT, EXTERNAL_SOURCE, INTERNAL_ENTITIES, | ||||
| id | String | ||||
| deployment | |||||
| externalSource |
38.12.7.11. StorageNetworkEntityInfoDeployment Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| namespace | String | ||||
| cluster | String | ||||
| listenPorts | List of DeploymentListenPort |
38.12.7.12. StorageNetworkEntityInfoType Copy linkLink copied to clipboard!
- INTERNAL_ENTITIES: INTERNAL_ENTITIES is for grouping all internal entities under a single network graph node
| Enum Values |
|---|
| UNKNOWN_TYPE |
| DEPLOYMENT |
| INTERNET |
| LISTEN_ENDPOINT |
| EXTERNAL_SOURCE |
| INTERNAL_ENTITIES |
38.12.7.13. StorageNetworkPolicy Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| id | String | ||||
| name | String | ||||
| clusterId | String | ||||
| clusterName | String | ||||
| namespace | String | ||||
| labels |
Map of | ||||
| annotations |
Map of | ||||
| spec | |||||
| yaml | String | ||||
| apiVersion | String | ||||
| created | Date | date-time |
38.12.7.14. StorageNetworkPolicyEgressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| to | List of StorageNetworkPolicyPeer |
38.12.7.15. StorageNetworkPolicyIngressRule Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ports | List of StorageNetworkPolicyPort | ||||
| from | List of StorageNetworkPolicyPeer |
38.12.7.16. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.12.7.17. StorageNetworkPolicyPeer Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| namespaceSelector | |||||
| ipBlock |
38.12.7.18. StorageNetworkPolicyPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| protocol | UNSET_PROTOCOL, TCP_PROTOCOL, UDP_PROTOCOL, SCTP_PROTOCOL, | ||||
| port | Integer | int32 | |||
| portName | String |
38.12.7.19. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.12.7.20. StorageNetworkPolicySpec Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| podSelector | |||||
| ingress | List of StorageNetworkPolicyIngressRule | ||||
| egress | List of StorageNetworkPolicyEgressRule | ||||
| policyTypes | List of StorageNetworkPolicyType |
38.12.7.21. StorageNetworkPolicyType Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_NETWORK_POLICY_TYPE |
| INGRESS_NETWORK_POLICY_TYPE |
| EGRESS_NETWORK_POLICY_TYPE |
38.12.7.22. StorageProtocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| UNSET_PROTOCOL |
| TCP_PROTOCOL |
| UDP_PROTOCOL |
| SCTP_PROTOCOL |
38.12.7.23. V1NetworkEdgeProperties Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, | ||||
| lastActiveTimestamp | Date | date-time |
38.12.7.24. V1NetworkEdgePropertiesBundle Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| properties | List of V1NetworkEdgeProperties |
38.12.7.25. V1NetworkGraph Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| epoch | Long | int64 | |||
| nodes | List of V1NetworkNode |
38.12.7.26. V1NetworkGraphDiff Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| DEPRECATEDNodeDiffs | Map of V1NetworkNodeDiff | ||||
| nodeDiffs | Map of V1NetworkNodeDiff |
38.12.7.27. V1NetworkNode Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| internetAccess | Boolean | ||||
| policyIds |
List of | ||||
| nonIsolatedIngress | Boolean | ||||
| nonIsolatedEgress | Boolean | ||||
| queryMatch | Boolean | ||||
| outEdges |
38.12.7.28. V1NetworkNodeDiff Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| policyIds |
List of | ||||
| DEPRECATEDOutEdges | |||||
| outEdges | |||||
| nonIsolatedIngress | Boolean | ||||
| nonIsolatedEgress | Boolean |
38.12.7.29. V1NetworkPolicyInSimulation Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| policy | |||||
| status | INVALID, UNCHANGED, MODIFIED, ADDED, DELETED, | ||||
| oldPolicy |
38.12.7.30. V1NetworkPolicyInSimulationStatus Copy linkLink copied to clipboard!
| Enum Values |
|---|
| INVALID |
| UNCHANGED |
| MODIFIED |
| ADDED |
| DELETED |
38.12.7.31. V1SimulateNetworkGraphResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| simulatedGraph | |||||
| policies | List of V1NetworkPolicyInSimulation | ||||
| added | |||||
| removed |
38.13. GetDiffFlowsFromUndoModificationForDeployment Copy linkLink copied to clipboard!
GET /v1/networkpolicies/undobaselinecomparison/{id}
38.13.1. Description Copy linkLink copied to clipboard!
38.13.2. Parameters Copy linkLink copied to clipboard!
38.13.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| id | X | null |
38.13.3. Return Type Copy linkLink copied to clipboard!
38.13.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.13.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.13.6. Samples Copy linkLink copied to clipboard!
38.13.7. Common object reference Copy linkLink copied to clipboard!
38.13.7.1. DeploymentListenPort Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| port | Long | int64 | |||
| l4protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.13.7.2. NetworkEntityInfoExternalSource Copy linkLink copied to clipboard!
Update normalizeDupNameExtSrcs(…) in central/networkgraph/aggregator/aggregator.go whenever this message is updated.
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| cidr | String | ||||
| default | Boolean |
|
38.13.7.3. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.13.7.3.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.13.7.4. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.13.7.5. StorageL4Protocol Copy linkLink copied to clipboard!
| Enum Values |
|---|
| L4_PROTOCOL_UNKNOWN |
| L4_PROTOCOL_TCP |
| L4_PROTOCOL_UDP |
| L4_PROTOCOL_ICMP |
| L4_PROTOCOL_RAW |
| L4_PROTOCOL_SCTP |
| L4_PROTOCOL_ANY |
38.13.7.6. StorageNetworkBaselineConnectionProperties Copy linkLink copied to clipboard!
NetworkBaselineConnectionProperties represents information about a baseline connection next available tag: 4
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| ingress | Boolean | ||||
| port | Long | int64 | |||
| protocol | L4_PROTOCOL_UNKNOWN, L4_PROTOCOL_TCP, L4_PROTOCOL_UDP, L4_PROTOCOL_ICMP, L4_PROTOCOL_RAW, L4_PROTOCOL_SCTP, L4_PROTOCOL_ANY, |
38.13.7.7. StorageNetworkEntityInfo Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| type | UNKNOWN_TYPE, DEPLOYMENT, INTERNET, LISTEN_ENDPOINT, EXTERNAL_SOURCE, INTERNAL_ENTITIES, | ||||
| id | String | ||||
| deployment | |||||
| externalSource |
38.13.7.8. StorageNetworkEntityInfoDeployment Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| name | String | ||||
| namespace | String | ||||
| cluster | String | ||||
| listenPorts | List of DeploymentListenPort |
38.13.7.9. StorageNetworkEntityInfoType Copy linkLink copied to clipboard!
- INTERNAL_ENTITIES: INTERNAL_ENTITIES is for grouping all internal entities under a single network graph node
| Enum Values |
|---|
| UNKNOWN_TYPE |
| DEPLOYMENT |
| INTERNET |
| LISTEN_ENDPOINT |
| EXTERNAL_SOURCE |
| INTERNAL_ENTITIES |
38.13.7.10. V1GetDiffFlowsGroupedFlow Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| properties |
38.13.7.11. V1GetDiffFlowsReconciledFlow Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| entity | |||||
| added | |||||
| removed | |||||
| unchanged |
38.13.7.12. V1GetDiffFlowsResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| added | List of V1GetDiffFlowsGroupedFlow | ||||
| removed | List of V1GetDiffFlowsGroupedFlow | ||||
| reconciled | List of V1GetDiffFlowsReconciledFlow |
38.14. GetUndoModification Copy linkLink copied to clipboard!
GET /v1/networkpolicies/undo/{clusterId}
38.14.1. Description Copy linkLink copied to clipboard!
38.14.2. Parameters Copy linkLink copied to clipboard!
38.14.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| clusterId | X | null |
38.14.3. Return Type Copy linkLink copied to clipboard!
38.14.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.14.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.14.6. Samples Copy linkLink copied to clipboard!
38.14.7. Common object reference Copy linkLink copied to clipboard!
38.14.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.14.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.14.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.14.7.3. StorageNetworkPolicyApplicationUndoRecord Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| clusterId | String | ||||
| user | String | ||||
| applyTimestamp | Date | date-time | |||
| originalModification | |||||
| undoModification |
38.14.7.4. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.14.7.5. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.14.7.6. V1GetUndoModificationResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| undoRecord |
38.15. GetUndoModificationForDeployment Copy linkLink copied to clipboard!
GET /v1/networkpolicies/undo/deployment/{id}
38.15.1. Description Copy linkLink copied to clipboard!
38.15.2. Parameters Copy linkLink copied to clipboard!
38.15.2.1. Path Parameters Copy linkLink copied to clipboard!
| Name | Description | Required | Default | Pattern |
|---|---|---|---|---|
| id | X | null |
38.15.3. Return Type Copy linkLink copied to clipboard!
38.15.4. Content Type Copy linkLink copied to clipboard!
- application/json
38.15.5. Responses Copy linkLink copied to clipboard!
| Code | Message | Datatype |
|---|---|---|
| 200 | A successful response. | |
| 0 | An unexpected error response. |
38.15.6. Samples Copy linkLink copied to clipboard!
38.15.7. Common object reference Copy linkLink copied to clipboard!
38.15.7.1. ProtobufAny Copy linkLink copied to clipboard!
Any contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
foo = any.unpack(Foo.getDefaultInstance());
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".
38.15.7.1.1. JSON representation Copy linkLink copied to clipboard!
The JSON representation of an Any value uses the regular representation of the deserialized, embedded message, with an additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field value which holds the custom JSON in addition to the @type field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| typeUrl | String |
A URL/resource name that uniquely identifies the type of the serialized protocol buffer message. This string must contain at least one \"/\" character. The last segment of the URL’s path must represent the fully qualified name of the type (as in | |||
| value | byte[] | Must be a valid serialized protocol buffer of the above specified type. | byte |
38.15.7.2. RuntimeError Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| error | String | ||||
| code | Integer | int32 | |||
| message | String | ||||
| details | List of ProtobufAny |
38.15.7.3. StorageNetworkPolicyApplicationUndoRecord Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| clusterId | String | ||||
| user | String | ||||
| applyTimestamp | Date | date-time | |||
| originalModification | |||||
| undoModification |
38.15.7.4. StorageNetworkPolicyModification Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| applyYaml | String | ||||
| toDelete | List of StorageNetworkPolicyReference |
38.15.7.5. StorageNetworkPolicyReference Copy linkLink copied to clipboard!
Next available tag: 3
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| namespace | String | ||||
| name | String |
38.15.7.6. V1GetUndoModificationForDeploymentResponse Copy linkLink copied to clipboard!
| Field Name | Required | Nullable | Type | Description | Format |
|---|---|---|---|---|---|
| undoRecord |