World Congress 2026 Europe Jul 10, 2026 Session details

Native Speed, Java Comfort: Calling Rust from the JVM with Project Panama

Gonzalo Ortiz Jaureguizar

Ditch verbose JNI bindings forever. Project Panama transforms Java 22 into a seamless orchestrator for optimized Rust ecosystems, granting native speed without sacrificing JVM comfort.

Pause
Mute Enter Fullscreen
#1 about 3 min

Motivations for calling native code from Java

The primary reasons to bridge Java and native languages like Rust lie in ecosystems and ergonomics rather than just raw performance.

#2 about 3 min

Comparing JNI and Project Panama philosophies

JNI expects native libraries to be aware of the JVM, whereas Project Panama treats native libraries purely as uncoupled native code.

#3 about 2 min

Adding integers with JNI and Project Panama

A side-by-side comparison reveals JNI's complex native glue code against Panama's simpler native implementation but more verbose Java bindings.

#4 about 4 min

Processing regular expressions and passing string variables

Sending strings to native code requires copying UTF-8 bytes to off-heap memory so the garbage collector does not move them.

#5 about 2 min

Managing off-heap memory lifecycles with arenas

Project Panama introduces arenas to safely allocate and automatically deallocate off-heap memory blocks based on desired object lifecycles.

#6 about 3 min

Allocating and reusing native memory objects

Maintaining a persistent native handle inside an object allows reusing expensive structures like compiled regex engines without recompiling them.

#7 about 3 min

Returning complex structures from native code

Extracting multiple data points from native structs requires carefully reading and mapping raw bytes using memory slice utilities.

#8 about 2 min

Generating Java bindings with jextract and cbindgen

Tools like jextract automate the generation of tedious Panama boilerplate by reading C header files produced from Rust with cbindgen.

#9 about 3 min

Implementing callbacks from Rust back to Java

Project Panama requires registering Java methods as native-callable function pointers to allow external Rust dependencies to invoke Java logic.

#10 about 4 min

Performance costs of native boundary crossings

Crossing the barrier between Java and native code introduces latency, making batch processing or memory-sharing formats like Apache Arrow favorable.

#11 about 1 min

Profiling native execution calls with async-profiler

Native code boundaries demand specialized external profiling tools rather than standard diagnostic utilities to accurately trace execution stacks.

#12 about 5 min

Tooling challenges with debugging, logging, and IDEs

Integrating native code within Java applications complicates developer workflows by fragmenting debugging environments, logging systems, and memory metric tracking.

Matching moments

6:21 min

Exploring JVM crashes and future debugging trends

Johannes Bechberger · LIVE

8:29 min

Discussion on JIT memory parameters and cross-language benchmarking

Daniel Strmečki · LIVE

2:13 min

Evaluating performance tradeoffs between JVM and native images

Timo Salm Timo Salm · LIVE

3:44 min

Comparing native GraalVM image throughput against traditional JVM instances

Eric Deandrea Eric Deandrea · World Congress 2025

9:46 min

Exploring the rising adoption and versatility of Rust

Chris Heilmann +2 · LIVE

21:18 min

Audience Q&A on developer advocacy and Java trends

Josh Long · LIVE

Upcoming sessions on this topic

Open session

World Congress 2026 North America

September 25, 2026 · 14:50–15:20

Stage 6

Look What Java Can Do Now: Live-Coding a GenAI MCP Server with the JAQ Stack

Suren Konathala

Senior Engineering Leader, Marketing & AdTech, AI GTM & Digital Experience Platforms, Java x AI

Suren Konathala
Open session

World Congress 2026 North America

September 24, 2026 · 16:10–16:40

Stage 4

From Cloud Native to Multi-Cloud Native: Write Once, Deploy Anywhere

Sandeep Pal

Principal Member of Technical Staff at Salesforce

Sandeep Pal
Open session

World Congress 2026 North America

September 25, 2026 · 10:20–10:50

Stage 2

API = Some REST and HTTP, right? RIGHT?!

Rustam Mehmandarov

Passionate computer scientist

Rustam Mehmandarov
Open session

World Congress 2026 North America

September 24, 2026 · 11:40–11:45

Outdoor Stage

One Environment, N Machines: Deterministic Builds for Humans and Agents

James Bayer, Morgan Helton

James Bayer
Morgan Helton
Open session

World Congress 2026 North America

September 24, 2026 · 16:50–17:20

Stage 1

When Humans Stop Writing Code: Rethinking Languages, Compilers, and Responsibility

Simon Auer

Organizer of flutter vienna meetup and CEO of marqably

Simon Auer
Open session

World Congress 2026 North America

September 25, 2026 · 15:30–15:40

Outdoor Stage

Offloading IoT State: Solving the Memory Crisis on Legacy Hardware

Pravin Nagare

Senior Software Engineer, Roku

Pravin Nagare