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

RFC: Dart wishlist on AWS (Lambda runtime, AWS Dart Service Clients) #3049

Open
abdallahshaban557 opened this issue May 15, 2023 · 9 comments
Labels
RFC Request for Comments

Comments

@abdallahshaban557
Copy link
Contributor

abdallahshaban557 commented May 15, 2023

AWS Lambda is a popular compute service that enables developers to run their code without having to manage servers. Currently, AWS Lambda supports multiple programming languages, including JavaScript, Python, Java, and C#. However, Dart is not officially supported, despite being a widely used language for building cross-platform applications.

In response to the demand from Dart and Flutter developers to use Dart for building for building fullstack applications, we propose exploring the feasibility of:

  1. Supporting Dart as an official AWS Lambda runtime.
  2. Developing an official AWS Dart SDK, allowing developers to integrate directly with AWS services.

Please provide us with your feedback, starting with but not limited to:

  • Which AWS services would you want to interact with using an AWS Dart SDK? Which use cases do you want to see supported on AWS Lambda with the Dart runtime?
  • What is the tooling you want to use to set up your Lambdas? Examples of that are:
    • Amplify CLI
    • AWS Cloud Development Kit (AWS CDK)
    • Serverless Application Model (AWS SAM)
  • Do you prefer deploying your code with serverless functions (Lambda), in serverful environments (Dart Frog, shelf, etc), or a combination of the two?
@abdallahshaban557 abdallahshaban557 pinned this issue May 15, 2023
@abdallahshaban557 abdallahshaban557 self-assigned this May 17, 2023
@jamilsaadeh97
Copy link
Contributor

Hi @abdallahshaban557 , that's a really good thing to add in my opinion.

Personally I use Lambdas a lot to complement my application with some business logic.

To answer your questions:

  • Which AWS services would you want to interact with using an AWS Dart SDK? Which use cases do you want to see supported on AWS Lambda with the Dart runtime?

DynamoDB and/or AppSync are found in 90% of my lambda functions to update items by listening to specific changes on a DynamoDB stream, post confirmation trigger to add a user to DynamoDB, . The rest is Pinpoint to send notification to specific users.

  • What is the tooling you want to use to set up your Lambdas?

I prefer Amplify CLI I feel more comfortable using it since it's faster to set up everything from permissions to specifying what resources should access what.

  • Do you prefer deploying your code with serverless functions (Lambda), in serverful environments (Dart Frog, shelf, etc), or a combination of the two?

I prefer with serverless functions. I don't have a reason why I do it this way, it's just the way I was introduced to when I first started using AWS and Amplify.

I feel it will be much better and efficient for dart and flutter developers to have the SDK in Dart. Speaking for myself, I will be the first one to migrate all my functions to Dart.

Thank you a lot for everything you guys do!

@abdallahshaban557
Copy link
Contributor Author

Hi @jamilsaadeh97 - thank you so much for your feedback!

@peter100u
Copy link

Compared to the new features you have proposed, I am more concerned about amplify studio-related functions and when they will be available to China. As far as I know, China is the second largest user group using flutter in the world, and then cannot use amplify-related services in China. I hope to further promote the development of this matter. Thank you very much.

@abdallahshaban557
Copy link
Contributor Author

abdallahshaban557 commented May 18, 2023

Hi @peter100u - thank you for this feedback! Please feel free to open up a Github issue to the Amplify Studio team using this link

@Schwusch
Copy link

Which AWS services would you want to interact with using an AWS Dart SDK?

You could make a somewhat data driven decision based on the popularity of these packages.

Which use cases do you want to see supported on AWS Lambda with the Dart runtime?

Personally, I have used this package successfully for Lambdas triggered through API Gateway, deployed with SAM: https://pub.dev/packages/aws_lambda_dart_runtime
It is somewhat cumbersome to deploy AOT compiled binaries, since Dart does not cross compile to other platforms, but it is seldom a problem at the companies I've worked at. The applications have been built/compiled in Linux pipelines, which is compatible with the provided runtime.

@dnys1
Copy link
Contributor

dnys1 commented May 19, 2023

You could make a somewhat data driven decision based on the popularity of these packages.

Good call! 😄

Personally, I have used this package successfully for Lambdas triggered through API Gateway, deployed with SAM: pub.dev/packages/aws_lambda_dart_runtime

Yes, we are planning to adopt and improve on that package.

It is somewhat cumbersome to deploy AOT compiled binaries, since Dart does not cross compile to other platforms, but it is seldom a problem at the companies I've worked at. The applications have been built/compiled in Linux pipelines, which is compatible with the provided runtime.

Agreed. We will likely try to leverage Docker as much as possible to make this process less painful.

@abdallahshaban557 abdallahshaban557 changed the title RFC: Dart wishlist on AWS (Lambda runtime, AWS SDK) RFC: Dart wishlist on AWS (Lambda runtime, AWS Dart SDK) May 24, 2023
@Jordan-Nelson Jordan-Nelson added the RFC Request for Comments label May 30, 2023
@abdallahshaban557 abdallahshaban557 changed the title RFC: Dart wishlist on AWS (Lambda runtime, AWS Dart SDK) RFC: Dart wishlist on AWS (Lambda runtime, AWS Dart Service Clients) Jun 28, 2023
@katallaxie
Copy link

You could make a somewhat data driven decision based on the popularity of these packages.

Good call! 😄

Personally, I have used this package successfully for Lambdas triggered through API Gateway, deployed with SAM: pub.dev/packages/aws_lambda_dart_runtime

Yes, we are planning to adopt and improve on that package.

It is somewhat cumbersome to deploy AOT compiled binaries, since Dart does not cross compile to other platforms, but it is seldom a problem at the companies I've worked at. The applications have been built/compiled in Linux pipelines, which is compatible with the provided runtime.

Agreed. We will likely try to leverage Docker as much as possible to make this process less painful.

I had added https://github.com/katallaxie/serverless-dart as supporting infrastructure to the Dart Runtime for AWS Lambda at the time. But this was probably not the best companion.

In general, the decision between AOT and compiling at runtime is a decision between warm-up times in Lambda. I choose AOT at the time because it offered the best performance. But to avoid the tooling problem, it could also be at runtime.

@cto-leaps
Copy link

Any evolution on this project?

@henryqum
Copy link

henryqum commented Jun 6, 2024

Hi,

we building dart only apps and we using sqs, lambda runtime, and create and event on EventBridge scheduler using signature_v4 lib and http requests, we plan to use dynemoDB and we wish we had official libraries from aws save much time and headache and let you use more aws easily, there was once official lambda runtime

Thanks a lot

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

No branches or pull requests

9 participants