Deploy Spring Boot Serverless CRUD API to AWS Lambda 🔥 | API Gateway |

Поділитися
Вставка
  • Опубліковано 7 січ 2025

КОМЕНТАРІ • 101

  • @amaradhipadmaja9232
    @amaradhipadmaja9232 6 місяців тому +13

    What a beautiful example, I tried each step and Absolutely worked, and created Employee API deployed using API Gateway and Lambda function. Thank you Basant ji :)

  • @faixan13
    @faixan13 6 місяців тому +6

    another day another unique content :)
    Please ask everyone to delete the instance of lambda and api gateway in the end :D otherwise on free account also will get charge after consuming enough hours. I have faced this in the past.

    • @theshivrajofficial8444
      @theshivrajofficial8444 6 місяців тому +2

      same here bro...2 years ago i followed his tutorial and forgot to delete the resourse. then i got huge bill with free tire

    • @Javatechie
      @Javatechie  6 місяців тому +4

      Yes it's good point somehow I missed to update at end of the video . But I Don't think it will charge more as it's a lambda function and you need to only pay as used .

  • @krishnamurthynazare1040
    @krishnamurthynazare1040 3 місяці тому +2

    Hi Basant, your expertise and eagerness to teach, and simple approach is really admirable.

  • @rohannagar5263
    @rohannagar5263 2 місяці тому +1

    Thank you for the wonderful tutorial on AWS lambda. Please create a tutorial on deploying Java app using Aws ECS service.

  • @aditipai7289
    @aditipai7289 3 місяці тому +1

    This is so well explained! Keep up with the good work

  • @vino7tech
    @vino7tech 6 місяців тому +1

    Hi Basant. Thank you so much for your wonderful real-time example. Thank you for your valuable time for creating this video.

  • @govardhanp3239
    @govardhanp3239 6 місяців тому +1

    Doing great job sir keep it up ..ur doing great service giving such a knowledge for free of cost hats for you

  • @gopisambasivarao5282
    @gopisambasivarao5282 6 місяців тому +1

    Appreciate your efforts Basant. Thank You! God bless you.😊

  • @pawan_aman_vlogs
    @pawan_aman_vlogs 6 місяців тому +1

    Exactly what I was looking for. Thank you

  • @MuayViaura
    @MuayViaura 4 місяці тому

    Great lecture! Simple and obious!!
    Thank you very much!!

  • @RAVIKUMAR-bh1cd
    @RAVIKUMAR-bh1cd 5 місяців тому +1

    Great explanation. Very Thankful to you.

  • @yugandharreddynalabolu
    @yugandharreddynalabolu 5 місяців тому +1

    followed same steps as in this video and able to do. Thank you

  • @vivektheartist
    @vivektheartist 4 місяці тому +1

    Great Example. Thank You

  • @praveens2272
    @praveens2272 13 днів тому

    Bro you need to explain how lambda works i mean how it handles requests and template, connection between SAM template and API gateway. Code walk through is fine. Lamda use cases are different. ECS with fargate auto scaling is best for backend apis.

  • @gajananjagdale3957
    @gajananjagdale3957 6 місяців тому +2

    Thank you sir for this precious video.

  • @saikumardasari4220
    @saikumardasari4220 6 місяців тому +2

    Exllent topics doing @techie
    Please do one video on ci-cd with spring micro service into aws eks

  • @mrinalsharma4137
    @mrinalsharma4137 5 місяців тому

    Great example. Tried and worked for very first time. Basant can you help with security examples for accessing these lambda functions from api gateway?

  • @yshkhre
    @yshkhre 15 днів тому

    This was really helpful. How can we enable lambda function url and use that for invoking these controller apis. I tried your code but it doesnt work with lambda function urls as it cannot be deserialized to SpringbootLambdaContainerHandler

  • @Francisco-co3lb
    @Francisco-co3lb 4 місяці тому +1

    Hello. I managed to create a jar file, put it on an S3 Bucket an uploaded to the lambda function with success. However, when I try to call any test i get the error Class not found: com.project.cr01.StreamLambdaHandler. The handler configurations has the full path, as in "com.project.cr01.StreamLambdaHandler::handleRequest". I did not create a zip as I was having a lot of errors with those libs, but the lambda accepts the jar, and I see it has all the needed files (i see them also when i download it from the lambda). Any ideas why it's not finding the StreamLambdaHandler class? Thank you so much

    • @Javatechie
      @Javatechie  4 місяці тому

      No buddy uploading jar won't work you need to create thin jar using zip and play with it . I am not sure why this restrictions

  • @eshikarya
    @eshikarya 20 днів тому

    Thanks for the wonderful video! I do have a follow up question.
    I'm using a similar project but connected to database - accordingly I have given configuration details for RDS in the applications.properties file.
    When I test the API gateway for AWS URL through postman it works fine
    However, if I want to locally test the code on say localhost:8080 - I edit my application.properties to point to the local database usually localhost:3306 but I'm getting error - connection refused. Why does this happen?
    Is it due to the Streamhandler class that exists in this project?

  • @muralikrishna-qh6vg
    @muralikrishna-qh6vg Місяць тому

    Excellent approach, thanks for the video. Basant I have a basic question where exactly fit this solution and where to use the other existing docker-k8 approach?

  • @dineshkm7832
    @dineshkm7832 4 місяці тому

    I have a ELB url which have 3 node of app server in differenr AZ ... How and where we can implement lambda here .. please help .. How can we implement Lambda for ELB ( this ELB redirecting to direct to 3 app server and doing Load balancing )

  • @obito9700
    @obito9700 13 днів тому

    Hi Bro,
    I didn't get how the state of list is maintained, won't the list data removed after each lambda run? How the data still persist in the list?

  • @sreenureddy994
    @sreenureddy994 6 місяців тому +1

    Appreciate your efforts. Can you please add security also for the same if possible

  • @surajjoshi6640
    @surajjoshi6640 5 місяців тому

    What if our spring boot application has log4j2 integrated...How do we ensure it is able to log our custom message to the log file??.

  • @grrlgd3835
    @grrlgd3835 6 місяців тому +1

    thanks JT. How do you get to know about the Maven Archetype to use in the first place ? what reference's do you use to learn about this ? great content as ever.

    • @Javatechie
      @Javatechie  6 місяців тому +1

      Hello buddy. I was searching this deployment in medium and then found this solution so thought to share

  • @hunterxdk
    @hunterxdk 6 місяців тому +1

    Thanks sir, much needed.❤

  • @kashmca
    @kashmca 6 місяців тому +1

    Great Demo. Thanks! Keep up the good work!. Can you explain how to debug this if we wanted to?

  • @hasithawickramanayaka6727
    @hasithawickramanayaka6727 5 місяців тому

    what if we have multiple services such as course service inside the same spring boot project how can deploy it in to the lambda and what would be best approach ?

  • @architjain798
    @architjain798 3 місяці тому +1

    Since you haven't used any database, how is the data being persisted, given that Lambda functions are stateless?

    • @Javatechie
      @Javatechie  3 місяці тому

      How stateless relevant with db?

  • @tejach3087
    @tejach3087 5 місяців тому +1

    Can you help me with below question like what are the steps need to be done
    My use case is for example I have to write cloud watch trigger which triggers the lambda and I want to hit only get API only
    So I want to hit the get api continuously using lambda and cloudwatch trigger

    • @Javatechie
      @Javatechie  5 місяців тому

      No idea need to check this buddy

    • @tejach3087
      @tejach3087 5 місяців тому +1

      @@Javatechie Ok sir, if there is any update please post here. Thanks 😊

  • @yravi37
    @yravi37 Місяць тому

    K8s with Docker will have multiple nodes created I think that itself is enough for scaling up and scaling down right , I am still not convinced with how better this AWS Lambda when compared to Docker with k8s., there might be auto scaling facility available in Docker right ?

  • @PontesesEduardo
    @PontesesEduardo 6 місяців тому

    Thank you so much! very nice explanation.

  • @deepakmishra169
    @deepakmishra169 6 місяців тому +3

    I did this 5 years ago and faced a lot of cold start problems then shifted to node.js at last 😢 is the cold start issue resolved now these days ?

    • @itsnarahari
      @itsnarahari 6 місяців тому

      😂

    • @tofuyam7361
      @tofuyam7361 6 місяців тому +1

      its been reduce by snapstart but still takes seconds. I try Quarkus + graal native compile and it is very fast

    • @NikhilJain08
      @NikhilJain08 6 місяців тому +1

      Same issue so I moved to Google cloud run. Cold boot issues

  • @shivshankar4010
    @shivshankar4010 3 місяці тому

    Followed each step but getting 502 Gateway Timeout issue. What could the issue can you please help me to resolve

  • @bikaskumar5904
    @bikaskumar5904 2 місяці тому +1

    Thanks for good tutorial, a good reference.. can u suggest how can we integrate this above lambda project to aws loadbalancer to access the apis

  • @anubhavpandey5182
    @anubhavpandey5182 6 місяців тому +1

    sir please do share guide for how to deploy application which has oauth2 (google,github)

  • @MohaideenA
    @MohaideenA 4 місяці тому

    How to use Springboot features like JPA and stuffs for S3event instead of APIGateway ?

  • @SANDIPKUMAR-es7qh
    @SANDIPKUMAR-es7qh 2 місяці тому

    It was a nice & informative video, but i wanted to understand why the project was created by Intellij idea and not from spring initialzr. Because i was trying to create from spring initializr and couldn't find spring serverless dependancy

  • @deepakmishra169
    @deepakmishra169 6 місяців тому +1

    One more question is graal vm integrated in archetype? Because I saw very few logs after the spring logo on console

    • @Javatechie
      @Javatechie  6 місяців тому +1

      Need to check buddy. Will update you

  • @2RAJ21
    @2RAJ21 6 місяців тому +1

    thank u for your guide about AWSLambda and Api gateway.
    how to remove this services after use??

    • @Javatechie
      @Javatechie  6 місяців тому +1

      Just delete the function

    • @2RAJ21
      @2RAJ21 6 місяців тому +1

      @@Javatechie thank you.

  • @tusharfasate7388
    @tusharfasate7388 6 місяців тому +1

    Still not clear why we used aws lambda here. What other things it did here which ECS or EKS cannot do?

    • @ManishTiwari-or8zt
      @ManishTiwari-or8zt 6 місяців тому +3

      Using AWS lamda you dont have to manage the server/machine like EC2, EBS, EKS. Using lamda just you need to give the jar/war files. Even scaling also will be taken care by lamda if more traffic l.

    • @hunterxdk
      @hunterxdk 6 місяців тому +2

      Bro Lambda can auto scale itself horizontally if there are unprecedented traffic on your requests..... for example. Your application has threshold of 1000 request per second which is hosted on 2 core 2Ghz frequency server with 4GB RAM. Lambda can allocate better resources for the time period in which there are 1000+ requests per second in your case. Then later when the traffic is low then it can deallocate the extra resource in the server... which can save subscription charges in comparison to EC2 instance where you can't have this privilege.

  • @abj7111
    @abj7111 3 місяці тому +2

    very nice explanation. big thanks sir 🙏🙏
    i saw aws username that was devOps4developer. are you planning to create new course devOps4developers?

    • @Javatechie
      @Javatechie  3 місяці тому +1

      This live Course already completed brother . You can checkout recorded session of that

    • @abj7111
      @abj7111 3 місяці тому +1

      @@Javatechie ok sir. thank you. i already checked as a devops4devloper in playlist but did not find. will check again.

    • @Javatechie
      @Javatechie  3 місяці тому +1

      No checkout description of any video you will find the course link . Just go through syllabus once

    • @abj7111
      @abj7111 3 місяці тому

      @@Javatechie ok. sir. Thanks again.

  • @rohatgianu
    @rohatgianu 2 місяці тому

    I have one question Not related to this topic but related to java . How do you load millions of record in java

  • @universal4334
    @universal4334 6 місяців тому

    I'm not sure my question is vaild or not, but the spring boot app should be running in tomcat inorder to accept request right ? Will lambda keep on running ? I know that it only startup when request hit lambda, will tomcat start when it get request or it keep on running ? If yes lambda only run for 15 mins right ?

  • @dineshkm7832
    @dineshkm7832 4 місяці тому +1

    By deploying this wat ..will it can connect to RDS too ?

    • @Javatechie
      @Javatechie  4 місяці тому +1

      Yes just configure RDS instance in your code 😀

    • @dineshkm7832
      @dineshkm7832 4 місяці тому

      thx

    • @dineshkm7832
      @dineshkm7832 4 місяці тому

      @@Javatechiesir they api gateway availability etc will b taken care by AWS ? 2- how we can customize gate way url as per company name 3- any aws course u providing for all this ?

    • @Javatechie
      @Javatechie  4 місяці тому

      Yes you can specify domain url, you have the option to specify it while creating Gateway. Exactly didn't remember the page but yes we can customize it .

  • @RameshDornala-b3f
    @RameshDornala-b3f 6 місяців тому

    can you please do a video by adding dynamo db as database for crud operations using Springboot

  • @Jitendra-cl7ru
    @Jitendra-cl7ru 6 місяців тому +1

    Sir I Have hit the end point using post but response is value is null, Status code is Ok like 201, plz sir help me where is my mistake

    • @Javatechie
      @Javatechie  6 місяців тому

      Can you check it in your local first

    • @Jitendra-cl7ru
      @Jitendra-cl7ru 6 місяців тому +1

      @@Javatechie okay I will check and thank u so much sir
      for reply me

    • @Javatechie
      @Javatechie  6 місяців тому

      @@Jitendra-cl7ru no problem please check and let me know if issue still persists

  • @reeeeel2858
    @reeeeel2858 6 місяців тому

    Is spring boot still relevant in industry with the arrival of node js support for backend development? Would it be a time waste to learn spring boot ?

  • @debapriyadasgupta6534
    @debapriyadasgupta6534 6 місяців тому

    Sir, is it necessary to install Maven separately to package the application?

  • @ChristoJose
    @ChristoJose 6 місяців тому

    If i want to call this Api from other application,then how i can do it ?

  • @acp3012
    @acp3012 2 місяці тому +1

    it is really an useful vedio. is there any option to run this app locally before depoly into AWS?

    • @Javatechie
      @Javatechie  2 місяці тому +1

      Yes we have some CLI from aws need to explore that and update you 👍

    • @acp3012
      @acp3012 2 місяці тому

      @@Javatechie OR else if any spring boot api created thro Spring initializer can be converted to AWS lambda. Anyhow your work is awesome dude !

  • @raghusama4273
    @raghusama4273 6 місяців тому +2

    Please upload full length videos on SonarQube and J-Unit

  • @pradeepjoshi6611
    @pradeepjoshi6611 6 місяців тому

    how to test & debug lambda function locally ?

  • @itsnarahari
    @itsnarahari 6 місяців тому +1

    Bro If I open UA-cam for some other videos I see your video In list I literally forgot which Video I wanted to Play....I will just start watching your video first.......😊

    • @Javatechie
      @Javatechie  6 місяців тому

      Thank you for your word 😀. Keep learning buddy 👍

  • @MohaideenA
    @MohaideenA 4 місяці тому

    But why deploy as .zip file instead of jar?

  • @rahulkharapkar2716
    @rahulkharapkar2716 6 місяців тому +1

    how can we deploy it for free, just for resumes for showcasing recruiters

    • @Javatechie
      @Javatechie  6 місяців тому

      Lambda won't charge more . You will pay only when you used it . Regarding free will check and update

  • @razatech22
    @razatech22 6 місяців тому

    We need a latest microservices video

  • @onkarkatkar2582
    @onkarkatkar2582 6 місяців тому +1

    Can i join your devops course now??

    • @Javatechie
      @Javatechie  6 місяців тому

      Yes you can join but I will not suggest you to join now as the course will be completed within next 15 days. So it's good to purchase this with half price I will announce that shortly 😀

    • @onkarkatkar2582
      @onkarkatkar2582 6 місяців тому

      Sure thank you

  • @BALAIT2020
    @BALAIT2020 Місяць тому +1

    Where is the use of lambda here??

    • @Javatechie
      @Javatechie  Місяць тому

      Please watch the video again

  • @tejastipre9787
    @tejastipre9787 6 місяців тому +1

    What if i have two controller and both of them have multiple get or put requests?
    In that case this api gateway configuration will not work

    • @Javatechie
      @Javatechie  6 місяців тому

      Yes why not because both url will.have different root url right?

  • @raghusama4273
    @raghusama4273 6 місяців тому

    Please upload full length videos on SonarQube and J-Unit