Skip to content

Implement basic persistence for lambda v2#7913

Merged
dominikschubert merged 5 commits intomasterfrom
lambda-v2-persistence
Mar 21, 2023
Merged

Implement basic persistence for lambda v2#7913
dominikschubert merged 5 commits intomasterfrom
lambda-v2-persistence

Conversation

@dominikschubert
Copy link
Member

@dominikschubert dominikschubert commented Mar 20, 2023

Adds a first iteration on basic persistence for the new lambda v2 provider.

Changes

  • Start loaded lambda function versions. => Detects lambdas that need to start by checking if they have a VersionManager assigned
  • Start event source listeners (note: restoring a dynamodbstreams event source mapping is currently broken because the dynamodbstreams provider doesn't properly support persistence yet) => test skipped for now

Left to do (in a later PR)

@dominikschubert dominikschubert self-assigned this Mar 20, 2023
@dominikschubert dominikschubert temporarily deployed to localstack-ext-tests March 20, 2023 09:56 — with GitHub Actions Inactive
@coveralls
Copy link

coveralls commented Mar 20, 2023

Coverage Status

Coverage: 85.122% (-0.02%) from 85.142% when pulling 528248a on lambda-v2-persistence into 3b41e13 on master.

@github-actions
Copy link

github-actions bot commented Mar 20, 2023

LocalStack integration with Pro

       3 files  ±  0         3 suites  ±0   1h 33m 19s ⏱️ - 18m 0s
1 830 tests +  4  1 442 ✔️ +3  388 💤 +1  0 ±0 
2 554 runs  +10  1 809 ✔️ +4  745 💤 +6  0 ±0 

Results for commit 528248a. ± Comparison against base commit 3b41e13.

♻️ This comment has been updated with latest results.

@dominikschubert dominikschubert temporarily deployed to localstack-ext-tests March 20, 2023 15:01 — with GitHub Actions Inactive
@dominikschubert dominikschubert marked this pull request as ready for review March 20, 2023 15:01
@dominikschubert dominikschubert requested a review from dfangl as a code owner March 20, 2023 15:01
@dominikschubert dominikschubert requested a review from joe4dev March 20, 2023 15:03
Copy link
Member

@dfangl dfangl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems only "light" merging on a per service state is available now, so we need to shutdown the lambda service in before_state_load and then start it up in after_state_load.

@dominikschubert dominikschubert temporarily deployed to localstack-ext-tests March 20, 2023 19:45 — with GitHub Actions Inactive
@dominikschubert dominikschubert requested a review from dfangl March 21, 2023 08:14
@dominikschubert dominikschubert temporarily deployed to localstack-ext-tests March 21, 2023 08:19 — with GitHub Actions Inactive
Copy link
Member

@joe4dev joe4dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lambda persistence tests from branch lambda-persistence-tests succeed on macOS tests.persistence.services.test_lambda 👍

@dominikschubert dominikschubert temporarily deployed to localstack-ext-tests March 21, 2023 12:45 — with GitHub Actions Inactive
@dominikschubert dominikschubert requested a review from dfangl March 21, 2023 12:45
@dominikschubert dominikschubert merged commit b0887d6 into master Mar 21, 2023
@dominikschubert dominikschubert deleted the lambda-v2-persistence branch March 21, 2023 15:01
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.

4 participants