All the highlights of the newest release

Javalin 3.0 brings a complete rework for WebSockets and event-setup

© Shutterstock / Waldemarus (modified)

Keeping up with its fast release cycle, Javalin, the lightweight web framework for Kotlin and Java, is back with a new update. Javalin 3.0 brings a complete rework for WebSockets and event-setup. Let’s take a closer look.

Javalin, the lightweight web framework for both Kotlin and Java developers comes back with a new release.

Javalin 3.0 brings some major changes including a complete rework for WebSockets and event-setup.

Let’s have a look at the most interesting highlights.

The updates

According to the official blog post, Javalin 3.0 features  ~6000 additions and ~2500 deletions.

Here are some of the major changes:

OpenAPI plugin – A much-requested feature is the support for OpenAPI (Swagger).

WebSockets – WebSockets have been completely reworked. More specifically:

  • WsContext has been introduced
  • wsBefore / wsAfter / wsException have been introduced
  • AccessManager can now handle WebSocket upgrade requests

Event-setup – Event-setup has been completely reworked, and more events have been added.

Other important improvements include:

  • Configuration has been moved from the Javalin class to JavalinConfig, which is an argument to app.create()
  • Validation has been improved and simplified
  • Extension has been renamed to Plugin and has been reworked
  • Standalone mode (running without Jetty) has been improved
  • A very small Vue (JavaScript frontend library) integration has been added
  • The internals have been completely refactored to make development easier
  • A lot of new config options have been added

Head over to the official release announcement for more details on the latest release.

SEE ALSO: Cthulhu: New open source chaos engineering tool for Java

Getting started

If you are eager to upgrade to Javalin 3.0, you should keep in mind that, as mentioned earlier, the changes in the configuration setup is one of the biggest new things in the latest release.

Make sure to check out the full list of the config options here.

You can also find the full migration guide here.

Eirini-Eleni Papadopoulou
Eirini-Eleni Papadopoulou was the editor for Coming from an academic background in East Asian Studies, she decided that it was time to go back to her high-school hobby that was computer science and she dived into the development world. Other hobbies include esports and League of Legends, although she never managed to escape elo hell (yet), and she is a guest writer/analyst for competitive LoL at TGH.

Inline Feedbacks
View all comments