Skip to content

Task 5#4

Open
Tati-Moon wants to merge 7 commits intomainfrom
task-5
Open

Task 5#4
Tati-Moon wants to merge 7 commits intomainfrom
task-5

Conversation

@Tati-Moon
Copy link
Owner

@Tati-Moon Tati-Moon commented Jun 30, 2024

Task 5

https://github.com/rolling-scopes-school/aws/blob/main/aws-developer/05_integration_with_s3/task.md

Links

image

Evaluation Criteria

  • 100/100

###Additional Scope (+30 points)

  • +10 (All languages) - importProductsFile lambda is covered by unit tests. You should consider to mock S3 and other AWS SDK methods so not trigger actual AWS services while unit testing.
  • +10 (All languages) - importFileParser lambda is covered by unit tests.
  • +10 (All languages) - At the end of the stream the lambda function should move the file from the uploaded folder into the parsed folder (move the file means that file should be copied into a new folder in the same bucket called parsed, and then deleted from uploaded folder)

image

Task 5.1

Created and configured a new S3 bucket with a folder called 'uploaded'

Task 5.2

  1. Created a Lambda function importProductsFile to handle HTTP GET requests.
  2. Added API /import.
  3. Added necessary configurations to pass the name parameter in the request.
  4. Updated the stack with policies to allow Lambda functions to interact with S3.
  5. Updated the import property in the API paths configuration to integrate the new Lambda endpoint.

image

Task 5.3

  1. Created a Lambda function importFileParser to handle S3 events.
  2. The function is triggered by s3:ObjectCreated:* events.
  3. Updated the stack to configure the S3 event trigger for the importFileParser Lambda function.
  4. Ensured that the Lambda function has the necessary permissions to read from the S3 bucket and log to CloudWatch.
    image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant