Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DRIVERS-2384 FaaS testing spec clarifications #1445

Merged
merged 2 commits into from
Aug 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions source/faas-automated-testing/faas-automated-testing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ For the initial local setup the following are required:
- The docker daemon running on the local machine.
- The `AWS SAM CLI <https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/install-sam-cli.html>`_

The following environment variables MUST be present:
AWS access MUST be configured, either through ``$HOME/.aws/credentials`` or
with the following environment variables:

- `AWS_ACCESS_KEY_ID`
- `AWS_SECRET_ACCESS_KEY`
Expand Down Expand Up @@ -206,6 +207,14 @@ to /mongodb and if it also contains Resources.Handler modify that to mongodb as
Path: /mongodb
Handler: mongodb

If possible, install the current driver under test into the lambda environment,
to avoid having to release the driver in order to test features or catch
regressions. See docs on https://docs.aws.amazon.com/lambda/latest/dg/configuration-function-zip.html for how to create a .zip file deployment with
dependencies.

Start the local MongoDB instance. If using Docker Desktop on MacOS, set ``MONGODB_URI=mongodb://host.docker.internal:27017`` in order for the function
to be able to access the host port.

Run the function locally from the same directory where the template.yaml resides:

.. code:: none
Expand Down Expand Up @@ -261,7 +270,7 @@ variables. An explanation of the required environment is as follows:
+-------------------------------+-------------------------------------+
| AWS_REGION | The function AWS region |
+-------------------------------+-------------------------------------+
| AWS_ACCESS_KEY_ID | Assume role atuomatically sets this |
| AWS_ACCESS_KEY_ID | Assume role automatically sets this |
+-------------------------------+-------------------------------------+
| AWS_SECRET_ACCESS_KEY | Assume role automatically sets this |
+-------------------------------+-------------------------------------+
Expand Down Expand Up @@ -339,8 +348,7 @@ functions inside of it for setup, teardown, and execution:


Drivers MUST run the function on a single variant in Evergreen, in order to not
potentially hit the Atlas API rate limit. The variant itself MUST be either a
RHEL8 or Ubuntu 20 variant in order to have the SAM CLI installed.
potentially hit the Atlas API rate limit. The variant itself MUST have the SAM CLI installed.

Description of the behaviour of run-deployed-lambda-aws-tests.sh:

Expand Down
Loading