create_route
async
¶
create_route(
route_name: ResourceName,
mesh_name: ResourceName,
virtual_router_name: ResourceName,
spec: RouteSpec,
*,
config_overrides: Optional[AsyncAppMeshClientConfig] = None,
tags: Optional[TagList] = None,
client_token: Optional[str] = None,
mesh_owner: Optional[AccountId] = None,
) -> CreateRouteOutput
Creates a route that is associated with a virtual router.
You can route several different protocols and define a retry policy for a route. Traffic can be routed to one or more virtual nodes.
For more information about routes, see Routes.
Parameters:
-
route_name(ResourceName) –The name to use for the route.
-
mesh_name(ResourceName) –The name of the service mesh to create the route in.
-
virtual_router_name(ResourceName) –The name of the virtual router in which to create the route. If the virtual router is in a shared mesh, then you must be the owner of the virtual router resource.
-
spec(RouteSpec) –The route specification to apply.
-
tags(Optional[TagList], default:None) –Optional metadata that you can apply to the route to assist with categorization and organization. Each tag consists of a key and an optional value, both of which you define. Tag keys can have a maximum character length of 128 characters, and tag values can have a maximum length of 256 characters.
-
client_token(Optional[str], default:None) –Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. Up to 36 letters, numbers, hyphens, and underscores are allowed.
-
mesh_owner(Optional[AccountId], default:None) –The Amazon Web Services IAM account ID of the service mesh owner. If the account ID is not your own, then the account that you specify must share the mesh with your account before you can create the resource in the service mesh. For more information about mesh sharing, see Working with shared meshes.
Raises:
-
BadRequestException–The request syntax was malformed. Check your request syntax and try again.
-
ConflictException–The request contains a client token that was used for a previous update resource call with different specifications. Try the request again with a new client token.
-
ForbiddenException–You don't have permissions to perform this action.
-
InternalServerErrorException–The request processing has failed because of an unknown error, exception, or failure.
-
LimitExceededException–You have exceeded a service limit for your account. For more information, see Service Limits in the App Mesh User Guide.
-
NotFoundException–The specified resource doesn't exist. Check your request syntax and try again.
-
ServiceUnavailableException–The request has failed due to a temporary failure of the service.
-
TooManyRequestsException–The maximum request rate permitted by the App Mesh APIs has been exceeded for your account. For best results, use an increasing or variable sleep interval between requests.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_app_mesh/_services/async_app_mesh.py
2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 | |