Javalin

Languages and libraries

web framework library

SHOW HN2022

Legend

Javalin

I finished v5 of a JVM framework I've spent spent half a decade making

javalin.io

#java web framework#kotlin web framework#jetty#virtual threads#rest api

377points
136comments
#96of 2,570 in 2022
Top 4%of 2022 by points

How HN took it

LovedMost comments that take a side are positive

30 positive, 30 neutral or asking, 0 mixed, 5 critical, out of 65 comments about the project. Thread score +0.38.

Design: 6 for, 1 againstIdea: 3 for, 1 againstExecution: 2 for, 1 againstDocs: 1 for, 1 againstPerformance: 1 for, 0 against

The thread, comment by comment

Each row is a top-level comment and its replies, in HN's order. Select a cell to open that comment on HN.

positive neutral or mixed critical about another commenter or something else the maker

What HN said

What people liked

  • Simple, straightforward docs

    From 1 comment
    • I just wanted to say thank you for your work. The straightforward docs are some the best in my opinion when you want to go from "How do I do ..." to answer. I ended up using…
      iammiles on HN
  • Clean, minimal API and one-line hello world

    From 2 comments
    • I find that hello world example very pleasant to look at. Love that it's effectively a one-liner. ``` public static void main(String[] args) { var app =…
      simonw on HN
    • That's probably the first time I see a java web framework api that actually makes me want to try it.
      JodieBenitez on HN
  • Fast startup and lightweight compared to Spring Boot

    From 2 comments
    • I just started using this! Spring Boot seemed so convoluted, having to go to a website to even begin. And then to have the Tomcat dependency seemed like a heavy lift just to get…
      adamredwoods on HN
    • Rebuild and restart. Javalin itself starts in milliseconds (the test suite starts and stops servers across 600+ tests in less than 10 seconds). If you run in debug mode in IDEA,…
      tipsee on HN

Objections

  • No ORM or database layer included

    From 2 comments
    • From my understanding this framework doesn’t include an ORM. I consider the ORM one of the most important component for a web framework
      adibalcan on HN
    • Javalin offers way less, it's more or less just the web routing layer. No databases, no ORM, no config loading, etc.
      tipsee on HN
  • Hot reload requires restart or external tooling

    From 2 comments
    • Rebuild and restart. Javalin itself starts in milliseconds (the test suite starts and stops servers across 600+ tests in less than 10 seconds). If you run in debug mode in IDEA,…
      tipsee on HN
    • Looks nice. Does it support hot reload? We use Quarkus heavily at work and one of the nifty feature is its ability to hot reload (fast restart to be specific) within few…
      reactor on HN
  • Some callback-based APIs (websockets, SSE) seem at odds with virtual threads

    From 1 comment
    • I haven’t tried this framework, but just looking at some examples, the web sockets and sse seem a bit out of place. In a Loom world you’d expect these to use channels or queues…
      NightMKoder on HN

Requests

  • Hot reload support

    From 2 comments
    • Looks nice. Does it support hot reload? We use Quarkus heavily at work and one of the nifty feature is its ability to hot reload (fast restart to be specific) within few…
      reactor on HN
    • How does the dev tooling work? Rebuild & restart the app each time? I find working on any sizable codebase this can take minutes even on the latest spring-boot. Quakrus has an…
      helfire on HN
  • CORS and proxy protocol support

    From 1 comment
    • this is very cool. quick question though - do u have a gradle build setup ? im new to java and saw this problem on spring boot. That you needed to have this bunch of complex…
      sandGorgon on HN
  • GraalVM native compilation guidance

    From 1 comment
    • Congrats on v5. Have you tried it yet with GraalVM and native compilation? Any gotchas?
      kitd on HN

Questions

  • How virtual threads are used given Loom is preview

    From 2 comments
    • Given Project Loom hasn't been available, how does it utilise Virtual Threads already?
      heurisko on HN
    • If you run this on JDK19 with *--enable-preview*, Javalin will use Virtual Threads for the Server ThreadPool (as well as all other ThreadPools it has).
      tipsee on HN
  • How it compares to Ktor and Dropwizard

    From 2 comments
    • Congrats on the release! I reviewed Javalin lately and it was high on my list. We use quite a bit of Kotlin and look for a framework. I really dislike the magic that annotations…
      cies on HN
    • How does Javalin compare with Dropwizard which is also quite lightweight?
      rrampage on HN
  • Whether it supports rendering traditional server-side apps

    From 1 comment
    • Can we use this to render traditional apps (no js frameworks)?
      spapas82 on HN

Alternatives named

  • Spring Boot

    From 2 comments
    • I just started using this! Spring Boot seemed so convoluted, having to go to a website to even begin. And then to have the Tomcat dependency seemed like a heavy lift just to get…
      adamredwoods on HN
    • > Calling a constructor is DI. ‘new’ is the only DI framework required. This feels like the sane thing to do, but sadly for historical reasons this won't work with many (if not…
      KronisLV on HN
  • Ktor

    From 1 comment
    • Congrats on the release! I reviewed Javalin lately and it was high on my list. We use quite a bit of Kotlin and look for a framework. I really dislike the magic that annotations…
      cies on HN
  • Dropwizard

    From 1 comment
    • How does Javalin compare with Dropwizard which is also quite lightweight?
      rrampage on HN
  • Vert.x

    From 2 comments
    • Peeking int the docs, it reminds me a little bit of Vert-X. What do you think qbout such a statement?
      de6u99er on HN
    • I respect Vert.x a lot, so I'm flattered, but Vert.x is a huge beast with focus on performance. Javalin is basically a tiny UX layer on top of Jetty. I don't think they are very…
      tipsee on HN
  • Sparkjava

    From 1 comment
    • Javalin is great and a worthy successor to its predecessor Sparkjava
      voidfunc on HN

Category, keywords, summaries and labels on this page were made by AI (Thread Reader v2) and not checked by hand. Each point links to the comments it came from.

Add a badge to your READMEShown on HackerShow
[![Shown on HackerShow](https://hackershow.org/badge.svg)](https://hackershow.org/show/33068017)