Giter Club home page Giter Club logo

Comments (5)

alexcasalboni avatar alexcasalboni commented on June 12, 2024

Hi @usabe 👋 thanks for reaching out!

I've been thinking about implementing special support to power-tune Lambda functions behind an API Gateway endpoint.

The main challenge is that there are multiple integration types and the event your Lambda function expects is highly dependant on both integration type and any mapping template (Velocity) that your API Gateway is applying. An easy solution (or workaround) would be supporting only the default structure with a simple URL and METHOD mapping.

What payload structure are you using right now? Have you looked into the official payload structure for APIGW documentation?

from aws-lambda-power-tuning.

usabe avatar usabe commented on June 12, 2024

Hi, Alex,

Thank you for the explanation. Good to know that you have been thinking about supporting this. Indeed, to fully cover all those scenarios, there are a lot of work to do. For our case, I think the easy solution you mentioned to support the default structure with a simple URL and METHOD mapping should work. Could you please give it a quick update of this? Or how could we implement that?

I didn't check into the APIGW payload structure yet before this. Not very familiar with this. Do you mean we can add the http URL and METHOD into the payload and then apiGateway will pass this to the lambda function?

from aws-lambda-power-tuning.

alexcasalboni avatar alexcasalboni commented on June 12, 2024

@usabe yes, you'd need to "manually" construct the full payload (including url, method, headers, etc.).

The fastest solution right now would be printing out the payload structure that your function expects, and then building your power-tuning payload based on that (changing the URL/METHOD based on your tuning needs).

Simply use the JSON input as your payload input for the power-tuning state machine.

from aws-lambda-power-tuning.

usabe avatar usabe commented on June 12, 2024

Great. Then I'll try that. Thank you, Alex. Your help is really appreciated.

from aws-lambda-power-tuning.

alexcasalboni avatar alexcasalboni commented on June 12, 2024

Closing this for now. Please reopen if you need more help :)

from aws-lambda-power-tuning.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.