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

Suggestion - Lambda - InvokeCommandInput should accept a json object #2123

Closed
antoineaws opened this issue Mar 10, 2021 · 4 comments · Fixed by #4836
Closed

Suggestion - Lambda - InvokeCommandInput should accept a json object #2123

antoineaws opened this issue Mar 10, 2021 · 4 comments · Fixed by #4836
Assignees
Labels
feature-request New feature or enhancement. May require GitHub community feedback. p2 This is a standard priority issue

Comments

@antoineaws
Copy link

Is your feature request related to a problem? Please describe.

The SDK v3 for Lambda javascript function "InvokeCommand" takes in an InvocationRequest as input.
The InvocationRequest takes in a couple input, specifically the payload property is a uint8array.
So clients using the sdk v3 will need to always convert the object to a uint8array, we should do that for them under the hood.

Describe the solution you'd like

We should allow the payload to be a JSON object/string similar to the v2 sdk.

https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-lambda/modules/invocationrequest.html
https://github.com/aws/aws-sdk-js-v3/blob/49e2d61c80/clients/client-lambda/models/models_0.ts#L3122

Describe alternatives you've considered

I have considered reverting back to v2.

Additional context

N/A

@antoineaws antoineaws added the feature-request New feature or enhancement. May require GitHub community feedback. label Mar 10, 2021
@fcwheat
Copy link

fcwheat commented Mar 12, 2021

I'd also like to see this for the client-iot-data-plane PublishRequest interface.
https://github.com/aws/aws-sdk-js-v3/blob/1c47c181/clients/client-iot-data-plane/models/models_0.ts#L303
I'd imagine there are quite a few other payload fields that are behaving this way. For the time being this seemed to work fine when assigned to the payload field:

Buffer.from(JSON.stringify(payload))

@github-actions
Copy link

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Mar 14, 2022
@antoineaws
Copy link
Author

Team, we should keep this open until we hear back from the sdk team. (Adding this comment to flag request active)

@github-actions github-actions bot removed the closing-soon This issue will automatically close in 4 days unless further comments are made. label Mar 15, 2022
@AllanZhengYP AllanZhengYP self-assigned this Mar 16, 2022
@AllanZhengYP AllanZhengYP removed their assignment Sep 3, 2022
@RanVaknin RanVaknin added the p3 This is a minor priority issue label Feb 17, 2023
@RanVaknin RanVaknin added p2 This is a standard priority issue and removed p3 This is a minor priority issue labels Mar 7, 2023
@kuhe kuhe self-assigned this Jun 16, 2023
@github-actions
Copy link

github-actions bot commented Jul 5, 2023

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request New feature or enhancement. May require GitHub community feedback. p2 This is a standard priority issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants