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

Invoking Local Lambda via AWS CLI and SDK #12

Closed
sanathkr opened this issue Aug 11, 2017 · 2 comments
Closed

Invoking Local Lambda via AWS CLI and SDK #12

sanathkr opened this issue Aug 11, 2017 · 2 comments

Comments

@sanathkr
Copy link
Contributor

The ability to invoke sam local Lambda functions via the AWS CLI and SDK, by simply setting the endpoint. Today, you have to call sam local invoke to actually Invoke a Lambda function. This means, you can't port your existing integration tests that run both against the local Lambda environment and cloud.

SAM Local can provide a local HTTP endpoint that responds to Lambda Invoke API and invokes Lambda locally. You can simply point AWS CLI or SDK to this endpoint to run tests against it.

@sanathkr sanathkr added this to the 1.0.0 milestone Aug 11, 2017
@rohitpg
Copy link

rohitpg commented Sep 11, 2017

How to point AWS CLI or SDK to SAM LOCAL Lambda to run test?
Example: need aws sam local command equivalent to
aws lambda create-event-source-mapping
--region us-east-1
--function-name publishNewBark
--event-source streamARN
--batch-size 1
--starting-position TRIM_HORIZON

@jfuss
Copy link
Contributor

jfuss commented Jul 18, 2018

This was enabled through the sam local start-lambda command adding in v0.5.0

Closing

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

No branches or pull requests

3 participants