### Is there an existing issue for this?

- [X] I have searched the existing issues and read the documentation

### Question

After configuring it  withEnv("DYNAMODB_WRITE_ERROR_PROBABILITY", "1.0") — it is expected to throw dynamo throuput exception , but throwing 500 error - `(Service: DynamoDb, Status Code: 500, Request ID: null, Extended Request ID: null)","operationType":"PutItem","kinesisRecordMetaData":{"recordInsertionDate":"01-01-2021"}}, Response - PutObjectResponse(ETag="5435b0664a1337227d380fbd83ebcc89")

### Anything else?

_No response_
return connect_to_resource("dynamodb", env=env, region_name=region_name).Table(
                table_name
            )
        if "AccessDeniedException" in str(e):
            raise
    if sleep_after:
        
        time.sleep(sleep_after)
    return table
def get_apigateway_integration(api_id, method, path, env=None):
    apigateway = connect_to_service(service_name="apigateway", client=True, env=env)
    resources = apigateway.get_resources(restApiId=api_id, limit=100)
    resource_id = None
    for r in resources["items"]:
        if r["path"] == path:
            resource_id = r["id"]
    if not resource_id:
        raise Exception('Unable to find apigateway integration for path "%s"' % path)
    integration = apigateway.get_integration(
        restApiId=api_id, resourceId=resource_id, httpMethod=method
    )
    return integration
def get_apigateway_resource_for_path(api_id, path, parent=None, resources=None):
    if resources is None:
        apigateway = connect_to_service(service_name="apigateway")
        resources = apigateway.get_resources(restApiId=api_id, limit=100)
    if not isinstance(path, list):
        path = path.split("/")
    if not path:
        return parent