Policy-Based Routing allows GCP customers to specify flexibile routing policies for Layer 4 traffic traversing through the connected service.
Equality
Instances of this class created via copy-construction or copy-assignment always compare equal. Instances created with equal std::shared_ptr<*Connection>
objects compare equal. Objects that compare equal share the same underlying resources.
Performance
Creating a new instance of this class is a relatively expensive operation, new objects establish new connections to the service. In contrast, copy-construction, move-construction, and the corresponding assignment operations are relatively efficient as the copies share all underlying resources.
Thread Safety
Concurrent access to different instances of this class, even if they compare equal, is guaranteed to work. Two or more threads operating on the same instance of this class is not guaranteed to work. Since copy-construction and move-construction is a relatively efficient operation, consider using such a copy when using this class from multiple threads.
Constructors
PolicyBasedRoutingServiceClient(PolicyBasedRoutingServiceClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
PolicyBasedRoutingServiceClient const &
|
PolicyBasedRoutingServiceClient(PolicyBasedRoutingServiceClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
PolicyBasedRoutingServiceClient &&
|
PolicyBasedRoutingServiceClient(std::shared_ptr< PolicyBasedRoutingServiceConnection >, Options)
Parameters | |
---|---|
Name | Description |
connection |
std::shared_ptr< PolicyBasedRoutingServiceConnection >
|
opts |
Options
|
Operators
operator=(PolicyBasedRoutingServiceClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
PolicyBasedRoutingServiceClient const &
|
Returns | |
---|---|
Type | Description |
PolicyBasedRoutingServiceClient & |
operator=(PolicyBasedRoutingServiceClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
PolicyBasedRoutingServiceClient &&
|
Returns | |
---|---|
Type | Description |
PolicyBasedRoutingServiceClient & |
Functions
ListPolicyBasedRoutes(std::string const &, Options)
Lists PolicyBasedRoutes in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The parent resource's name. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networkconnectivity::v1::PolicyBasedRoute > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
ListPolicyBasedRoutes(google::cloud::networkconnectivity::v1::ListPolicyBasedRoutesRequest, Options)
Lists PolicyBasedRoutes in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networkconnectivity::v1::ListPolicyBasedRoutesRequest
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::networkconnectivity::v1::PolicyBasedRoute > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
GetPolicyBasedRoute(std::string const &, Options)
Gets details of a single PolicyBasedRoute.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. Name of the PolicyBasedRoute resource to get. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networkconnectivity::v1::PolicyBasedRoute > |
the result of the RPC. The response message type (google.cloud.networkconnectivity.v1.PolicyBasedRoute) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
GetPolicyBasedRoute(google::cloud::networkconnectivity::v1::GetPolicyBasedRouteRequest const &, Options)
Gets details of a single PolicyBasedRoute.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networkconnectivity::v1::GetPolicyBasedRouteRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::networkconnectivity::v1::PolicyBasedRoute > |
the result of the RPC. The response message type (google.cloud.networkconnectivity.v1.PolicyBasedRoute) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
CreatePolicyBasedRoute(std::string const &, google::cloud::networkconnectivity::v1::PolicyBasedRoute const &, std::string const &, Options)
Creates a new PolicyBasedRoute in a given project and location.
Parameters | |
---|---|
Name | Description |
parent |
std::string const &
Required. The parent resource's name of the PolicyBasedRoute. |
policy_based_route |
google::cloud::networkconnectivity::v1::PolicyBasedRoute const &
Required. Initial values for a new Policy Based Route. |
policy_based_route_id |
std::string const &
Required. Unique id for the Policy Based Route to create. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::PolicyBasedRoute > > |
A |
CreatePolicyBasedRoute(NoAwaitTag, std::string const &, google::cloud::networkconnectivity::v1::PolicyBasedRoute const &, std::string const &, Options)
Creates a new PolicyBasedRoute in a given project and location.
Specifying the NoAwaitTag
immediately returns the [google::longrunning::Operation
] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.
Parameters | |
---|---|
Name | Description |
|
NoAwaitTag
|
parent |
std::string const &
|
policy_based_route |
google::cloud::networkconnectivity::v1::PolicyBasedRoute const &
|
policy_based_route_id |
std::string const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
StatusOr< google::longrunning::Operation > |
CreatePolicyBasedRoute(google::cloud::networkconnectivity::v1::CreatePolicyBasedRouteRequest const &, Options)
Creates a new PolicyBasedRoute in a given project and location.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networkconnectivity::v1::CreatePolicyBasedRouteRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::PolicyBasedRoute > > |
A |
CreatePolicyBasedRoute(NoAwaitTag, google::cloud::networkconnectivity::v1::CreatePolicyBasedRouteRequest const &, Options)
Creates a new PolicyBasedRoute in a given project and location.
Specifying the NoAwaitTag
immediately returns the [google::longrunning::Operation
] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.
Parameters | |
---|---|
Name | Description |
|
NoAwaitTag
|
request |
google::cloud::networkconnectivity::v1::CreatePolicyBasedRouteRequest const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
StatusOr< google::longrunning::Operation > |
CreatePolicyBasedRoute(google::longrunning::Operation const &, Options)
Creates a new PolicyBasedRoute in a given project and location.
This method accepts a google::longrunning::Operation
that corresponds to a previously started Long Running Operation (LRO) and polls the status of the LRO in the background.
Parameters | |
---|---|
Name | Description |
operation |
google::longrunning::Operation const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::PolicyBasedRoute > > |
DeletePolicyBasedRoute(std::string const &, Options)
Deletes a single PolicyBasedRoute.
Parameters | |
---|---|
Name | Description |
name |
std::string const &
Required. Name of the PolicyBasedRoute resource to delete. |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::OperationMetadata > > |
A |
DeletePolicyBasedRoute(NoAwaitTag, std::string const &, Options)
Deletes a single PolicyBasedRoute.
Specifying the NoAwaitTag
immediately returns the [google::longrunning::Operation
] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.
Parameters | |
---|---|
Name | Description |
|
NoAwaitTag
|
name |
std::string const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
StatusOr< google::longrunning::Operation > |
DeletePolicyBasedRoute(google::cloud::networkconnectivity::v1::DeletePolicyBasedRouteRequest const &, Options)
Deletes a single PolicyBasedRoute.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::networkconnectivity::v1::DeletePolicyBasedRouteRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::OperationMetadata > > |
A |
DeletePolicyBasedRoute(NoAwaitTag, google::cloud::networkconnectivity::v1::DeletePolicyBasedRouteRequest const &, Options)
Deletes a single PolicyBasedRoute.
Specifying the NoAwaitTag
immediately returns the [google::longrunning::Operation
] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.
Parameters | |
---|---|
Name | Description |
|
NoAwaitTag
|
request |
google::cloud::networkconnectivity::v1::DeletePolicyBasedRouteRequest const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
StatusOr< google::longrunning::Operation > |
DeletePolicyBasedRoute(google::longrunning::Operation const &, Options)
Deletes a single PolicyBasedRoute.
This method accepts a google::longrunning::Operation
that corresponds to a previously started Long Running Operation (LRO) and polls the status of the LRO in the background.
Parameters | |
---|---|
Name | Description |
operation |
google::longrunning::Operation const &
|
opts |
Options
|
Returns | |
---|---|
Type | Description |
future< StatusOr< google::cloud::networkconnectivity::v1::OperationMetadata > > |