Questions tagged [sam]

Simple Asynchronous Messaging is a PHP framework that provides a very simple API that can be used to access a number of messaging middleware systems from PHP.

This extension provides access to the functionality of messaging and queueing systems, such as the IBM WebSphere MQSeries family of products, from PHP scripts. The interface is designed to make it extremely simple to do the more commonly required tasks such as deliver simple text messages to queues while still allowing skilled users to do more complex messaging operations. For many users the complexities of setting up numerous options can be simply ignored.

The SAM extension is a framework that provides a very simple API that can be used to access a number of messaging middleware systems. Currently the package includes built-in support for the MQTT (MQ Telemetry Transport) messaging protocol and support for the IBM Messaging and Queuing middleware products. SAM is designed to be readily extended to support other messaging systems and extension modules may be written in C or PHP.


Do not use this tag for the sequencing SAM file format.

194 questions
2
votes
1 answer

Sam template rest api, Can we have separate handler for each function event type?

Is it possible to have separate handler for one function but each event type. For example. Type: AWS::Serverless::Function Properties: FunctionName: ecommerce-lambda Handler: src/handlers/ecommerceHandler.handler. <--- HERE is…
2
votes
0 answers

AWS SAM + CDK missing packages

When running cdk synth, sam built -t cdk.out/.template then cdk deploy my build shows the packages in them, and all of the lambdas show they have the packages except one is missing the packages entirely
2
votes
2 answers

AWS SAM Deployment: Failed to create managed resources

When I try to deploy the hello world SAM application using sam deploy --guided, I get the following error. Configuring SAM deploy ====================== Looking for config file [samconfig.toml] : Not found Setting default…
2
votes
0 answers

Can't import (SyntaxError: Cannot use import statement outside a module)

Im building my first Lambda function, and wants to do it locally. So I have naturally installed SAM to do so. From what I understand, AWS recently pushed a new version that would allow ES6 syntax with import/export and so on. But this is not the…
Oakleaf
  • 393
  • 3
  • 14
2
votes
1 answer

how to build, package and deploy AWS SAM lambda function of python from azure Devops CI/CD pipeline to AWS

I used the aws sam lambda function(hello_world) template to create a project. I can build, invoke locally and deploy from local using sam command. Now, the code is in Azure repo. I used "python package" to do pipeline and deploy but I do not know…
Morshed
  • 165
  • 3
  • 16
2
votes
1 answer

Does AWS sam cli print template.yaml config file with all variables resolved

I have switched from serverless to sam cli. One useful function serverless had was serverless print which allowed you to print the output of your yaml file with all the local variables resolved. This was a useful tool for checking if your syntax is…
2
votes
1 answer

How do I install a specific version of python on alpine linux (python3.8)?

Currently I'm using a dind configuration in gitlab This dind works for me to deploy a dockerized lambda function through SAM. This is my before script - apk add --no-cache curl jq - apk add --no-cache python3 python3-dev py3-setuptools -…
Jesus Walker
  • 116
  • 10
2
votes
0 answers

How to build and deploy multiple lambdas from single repo using codepipeline?

UseCase: I have a codecommit repo that has 12 lambdas(6 nodejs and 6 python) and a cloud formation template. My goal is to build all the lambdas using codebuild and upload them as zip files to s3. After that, I have to pass the uploaded lambdas…
learner
  • 117
  • 2
  • 10
2
votes
1 answer

AWS::Events::Rule Input for target is not a valid JSON text

I have the following resource in my SAM template.yml: MetricsRule: Type: AWS::Events::Rule Properties: Name: MetricsRule Description: Puts metrics to the CloudWatch log group EventBusName: !FindInMap [LambdaConfig, !Ref stage,…
2
votes
2 answers

AWS: How to write to the local file system with 'sam local'?

I need to read a file in my lambda via sftp and save it locally for processing. The issue is that when running 'sam local' my lambda can only read from the local file system but not write to it.
marting
  • 165
  • 1
  • 8
2
votes
1 answer

AWS SAM APIGatewayProxyRequestEvent HttpMethod not set when starting API locally

I created an application with a AWS::SERVERLESS::FUNCTION, which has an HttpApi Event attached to it. I thought it would be a good idea to create one lambda per resource, so e.g. Post, Get and Put on /customer are all handled by a single lambda,…
Dominic
  • 61
  • 5
2
votes
1 answer

AWS SAM Unable to call Rekognition and access S3 from Lambda

I am trying to call the detectText method from Rekognition framework and it failed to call S3 bucket. I am not sure how to give roles in SAM Template. Below is my SAM template GetTextFunction: Type: AWS::Serverless::Function Properties: CodeUri:…
Raygun
  • 75
  • 5
2
votes
1 answer

Sharing code between multiple AWS Lambdas in a SAM app using Docker Containers

I have a SAM app with multiple Lambdas and some utility code I'd like to share between them. When packaging Lambdas using zip files, code sharing can be done with Lambda Layers. However, according to the AWS documentation, Lambda Layers are not…
2
votes
1 answer

Getting Build failed error on AWS SAM build

I got build failed error when i run sam build Error: PythonPipBuilder:ResolveDependencies - {future==0.18.2(sdist), wrapt==1.12.1(sdist)}
user15494683
2
votes
2 answers

AWS SAM golang lambda localhost connection refused to postgres

I'm unable to connect an AWS SAM lambda function to a local postgres instance. I'll be specific in a moment, but first let me say that the same code works for my coworker and that I've tried using Postgres within a docker container as well as…
Etwillms
  • 23
  • 4
1 2
3
12 13