Repository navigation
filter: AWS Lambda filter (initial version) - #10260
Conversation
This filter transform HTTP requests to AWS Lambda invocations. The filter supports pass-through only. Meaning, the request body is passed to Lambda as is. Note: Lambda requires the request to be in JSON format. In a later iteration, we'll wrap the headers the body in a JSON string before passing it to Lambda. The filter requires the ARN of the Lambda function and supports per-filter-config. When the per-filter configuration is used, the target cluster must be tagged with specific metadata. This indicates to the filter whether to process the request or to skip it. Lambda supports two invocation modes: - Synchronous (Request-Response) - Asynchronous (Event) This initial version of the filter supports the synchronous mode only. In a later iteration I'll add support for the asynchronous (Event-based) version. Signed-off-by: Marco Magdy <[email protected]>
Signed-off-by: Marco Magdy <[email protected]>
The patch is small (the actual code) so any line not covered results in a big drop in coverage. Signed-off-by: Marco Magdy <[email protected]>
Signed-off-by: Marco Magdy <[email protected]>
mattklein123
left a comment
There was a problem hiding this comment.
Thanks looks great overall. A few nits and questions. Can you also merge master which should fix coverage and then check the coverage report for the added code? I want to make sure there is full coverage for all the error paths. Thank you!
/wait
| If ``payload_passthrough`` is set to ``true``, then the payload is sent to Lambda without any transformations. | ||
| *Note*: This means you lose access to all the HTTP headers in the Lambda function. | ||
|
|
||
| However, if ``payload_passthrough`` is set to ``false``, then the HTTP request is transformed to a JSON payload with the following |
There was a problem hiding this comment.
This is not implemented yet, right? I'm a little confused about what is implemented right now versus what is not. Should you just remove the docs from this PR until it's actually implemented?
There was a problem hiding this comment.
I added it to get a review on the examples mainly. I can remove the parts of the documentation (and examples) that speak to features that are not implemented yet.
If you prefer to review documentation once at the end, that works too. LMK.
Signed-off-by: Marco Magdy <[email protected]>
Signed-off-by: Marco Magdy <[email protected]>
Signed-off-by: Marco Magdy <[email protected]>
Signed-off-by: Marco Magdy <[email protected]>
This filter transform HTTP requests to AWS Lambda invocations.
The filter supports pass-through only. Meaning, the request body
is passed to Lambda as is. Note: Lambda requires the request to be in
JSON format.
In a later iteration, we'll wrap the headers the body in a JSON string
before passing it to Lambda.
The filter requires the ARN of the Lambda function and supports
per-filter-config. When the per-filter configuration is used, the target
cluster must be tagged with specific metadata. This indicates to the
filter whether to process the request or to skip it.
Lambda supports two invocation modes:
This initial version of the filter supports the synchronous mode only.
In a later iteration I'll add support for the asynchronous (Event-based)
version.
Signed-off-by: Marco Magdy [email protected]