QueryParameterMatch
- class aws_cdk.aws_appmesh.QueryParameterMatch
Bases:
object
Used to generate query parameter matching methods.
- ExampleMetadata:
infused
Example:
# router: appmesh.VirtualRouter # node: appmesh.VirtualNode router.add_route("route-http2", route_spec=appmesh.RouteSpec.http2( weighted_targets=[appmesh.WeightedTarget( virtual_node=node ) ], match=appmesh.HttpRouteMatch( path=appmesh.HttpRoutePathMatch.exactly("/exact"), method=appmesh.HttpRouteMethod.POST, protocol=appmesh.HttpRouteProtocol.HTTPS, headers=[ # All specified headers must match for the route to match. appmesh.HeaderMatch.value_is("Content-Type", "application/json"), appmesh.HeaderMatch.value_is_not("Content-Type", "application/json") ], query_parameters=[ # All specified query parameters must match for the route to match. appmesh.QueryParameterMatch.value_is("query-field", "value") ] ) ) )
Methods
- abstract bind(scope)
Returns the query parameter match configuration.
- Parameters:
scope (
Construct
)- Return type:
Static Methods
- classmethod value_is(query_parameter_name, query_parameter_value)
The value of the query parameter with the given name in the request must match the specified value exactly.
- Parameters:
query_parameter_name (
str
) – the name of the query parameter to match against.query_parameter_value (
str
) – The exact value to test against.
- Return type: