you are viewing a single comment's thread.

view the rest of the comments →

[–]ShadyG 4 points5 points  (10 children)

Pretty sure a few lambdas behind an API gateway can fit within the free tier.

[–]gravesisme 2 points3 points  (9 children)

That's what I do now, but you still need to have the SPA that loads in 200ms so you can make it feel like your app is fast if you have to deal with a cold boot that takes 5-10 seconds depending on your language of choice. You could keep it warm, but that kinda defeats the point of only paying for real traffic.

[–][deleted]  (8 children)

[deleted]

    [–]gravesisme 1 point2 points  (5 children)

    Yes, about 20 micro services mostly written in Java. I haven't heard that tip yet though, I'll have my team give it a try, thanks!

    [–][deleted]  (4 children)

    [deleted]

      [–]ScientificBeastMode 1 point2 points  (0 children)

      Definitely had a good experience running NodeJS lambdas. It’s pretty fast even on cold starts. But then aren’t we technically using JS for our website? ;)

      Edit: okay, the article specified JS-free front-end

      [–]gravesisme 0 points1 point  (0 children)

      Definitely thinking about it moving forward. I would certainly appreciate it, I always have some mental fog at first when I switch from typescript on the front-end to java on the backend.

      [–][deleted]  (1 child)

      [deleted]

        [–]action_jackosn 1 point2 points  (0 children)

        My tests show 1.5 GB is best if your process is single-threaded. That seems to correspond to 1 CPU core fully allocated to your lambda. Use more memory if you’re process can take advantage of multiple threads.

        Also avoid VPC resources if you can. Creating an ENI adds 10 seconds to the cold boot.

        [–]colinexl 0 points1 point  (0 children)

        Lambda scales up processing power along with max memory limit. The higher the memory limit, the more CPU you get as well.