Measuring Java 11 Lambda cold starts with SnapStart - Part 3 Using Quarkus Framework

This page summarizes the projects mentioned and recommended in the original post on dev.to

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. AWSLambdaJavaSnapStart

    Different examples of solutions API Gateway->Lambda->DynamoDB with Lambda managed Java runtimes with different Lambda memory settings, compilation options, (a)synchronous HTTP clients, Lambda layers, GC algorithms and hardware architecture (x86 vs arm64) including Lambda SnapStart enabling and priming techniques to measure Lambda performance

    Let's look how to implement it with Quarkus. In the AWS SAM Template (template.yaml) we point the AWS Lambda function handler to the generic QuarkusStreamHandler implementation:

  2. CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  3. If we compare these metrics with AWS Lambda with plain Java (and AWS SDK for Java version 2) and Micronaut Framework with SnapStart enbled we'll notice that using the Micronaut Framework the average cold start with Quarkus is quite comparable with the first and better than the latter. If we compile our application with GraalVM Native Image and deploy our Lambda as Custom Runtime (which is beyond the scope if this article), we can further reduce the cold start to between 450 and 550ms, see the measurements for the comparable application.

  4. Spring Boot

    Spring Boot helps you to create Spring-powered, production-grade applications and services with absolute minimum fuss.

    In the next part of series we'll explore Spring Boot for writing Lambda functions and measure the cold start with and without enabling of the SnapSart.

  5. Quarkus

    Quarkus: Supersonic Subatomic Java.

    Quarkus Framework is Kubernetes Native Java stack (personally I don't understand this term :)) tailored for OpenJDK HotSpot and GraalVM, crafted from the best of breed Java libraries and standards. For us it's important that this framework is very well suited for writing Serverless applications. Like Micronaut, it gives us the possibility to create our application using the launcher or CLI, provides API Gateway integration, GraalVM (Native Image) integation, supports Maven und Gradle and much more. It also supports MicroProfile and Funqy for multi cloud solutions. It also processes annotations at compile time and doesn't use reflection, runtime byte code generation, runtime generated proxies and dynamic class loading.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Choosing the Right Java Microservices Framework: Spring Boot, Quarkus, Micronaut, and Beyond

    3 projects | dev.to | 3 Dec 2024
  • Is it okay to use com.sun.net.httpserver.HttpServer?

    3 projects | dev.to | 12 Nov 2022
  • why does java require tomcat?

    3 projects | /r/java | 9 May 2022
  • Quarkus 2.0 Delivers Continuous Testing, CLI and Supports Minimal JDK 11

    2 projects | /r/programming | 8 Aug 2021
  • 🏅 Http4k: Top 5 Server-Side Frameworks for Kotlin in 2022

    6 projects | dev.to | 15 Apr 2023