Cassini strictly implements Jakarta RESTful Web Services 4.0. If your application is already standard (spec annotations, no proprietary API), the migration is mostly a swap of the Maven runtime coordinates. This page documents the gotchas and the mappings.
|
Cassini is at |
From Jersey
| Jersey | Cassini | Note |
|---|---|---|
|
|
Standard spec. Jersey-isms ( |
|
|
Standard |
HK2 bridge ( |
|
Vauban resolves injection at build time, not via HK2. |
|
No proprietary extensions |
Cassini stays 100 % spec. Bean Validation must be wired manually (TODO post-1.0). |
|
Standard |
Hand-written impl (10 lines — see usage). |
// Before — Jersey + Grizzly
ResourceConfig config = new ResourceConfig().packages("com.example");
GrizzlyHttpServerFactory.createHttpServer(URI.create("http://0.0.0.0:8080/"), config);
// After — Cassini SE-Bootstrap
SeBootstrap.start(MyApplication.class, SeBootstrap.Configuration.builder()
.host("0.0.0.0").port(8080).build()).toCompletableFuture().join();
From RESTEasy
| RESTEasy | Cassini | Note |
|---|---|---|
|
|
Equivalent build-time path, without Quarkus. Champollion replaces Quarkus’s JSON binding. |
Vert.x transport |
Chappe ( |
Native virtual threads, no event-loop. Different concurrency model — see internals. |
Embedded Weld |
Vauban (Lite) optional |
Vauban is CDI 4.1 Lite, not Full. Verify you don’t rely on Full features (dynamic decorators, conversation scope, etc.). |
|
|
Standard JAX-RS Client 4.0 now shipped ( |
|
Same Jakarta REST 4.0 |
No change. |
From Helidon REST
Helidon SE 4 exposes a custom API (HttpRouting, Handler). Helidon MP runs Jersey under the hood — migration is then equivalent to "from Jersey" above.
For Helidon SE → Cassini, you need to rewrite to standard JAX-RS annotations. Cassini is not a "fluent routing" engine — it is a Jakarta REST engine.
From CXF (JAX-RS)
CXF tracks the spec closely. Migration is largely a Maven-coordinate swap and replacing <jaxrs:server> Spring/Blueprint with SeBootstrap.start(…).
JSON binding — heads-up
Jersey and RESTEasy default to Yasson or Jackson. Cassini delegates to Champollion:
-
Static serialization: add
champollion-codegen-aptto the build for new types. -
Standard
@JsonbProperty,@JsonbDateFormat,@JsonbTypeAdapterannotations supported. -
Jackson annotations (
@JsonProperty,@JsonIgnore…) not supported — convert to JSON-B.
Jakarta REST 4.0 annotations
All standard annotations are preserved. No expected change on user code if it is strictly spec-compliant.
Known pitfalls
-
Sub-resource locators (
@Pathon a method returning an instance): supported. Verify imports if the application used a proprietary variant. -
@Suspended AsyncResponse: supported; full chunked streaming is on milestone M2h (see TCK). -
SSE backpressure:
CassiniSseEventSinkbuffers in 0.1.0 — real-time streaming arrives in M2i. -
JAX-RS Client: a standard client now ships in
cassini-client(ClientBuilder.newClient(),java.net.http+ virtual threads). Client-side multipart entities remain limited — use an external client for those in the meantime. -
MicroProfile Config / Health / Metrics: wire via Vidocq Runtime (orchestrator) — Cassini alone does not configure MP.