# A practical look at JEP-389 in JDK16 with libsodium

DevFeed: [A practical look at JEP-389 in JDK16 with libsodium](<https://devfeed.tech/articles/a-practical-look-at-jep-389-in-jdk16-with-libsodium-26082.md>)

Original publisher: [Read original article](<https://blog.arkey.fr/2021/02/20/a-practical-look-at-jep-389-in-jdk16-with-libsodium/>)

Author: brice.dutheil@gmail.com (Brice Dutheil)

Published: 2021-02-20T15:01:06Z

Content type: tutorial

Language: en

Sources: [The Coffee Workshop](<https://devfeed.tech/sources/the-coffee-workshop.md>)

Topics: [Java](<https://devfeed.tech/topics/java.md>), [API](<https://devfeed.tech/topics/api.md>), [C](<https://devfeed.tech/topics/c.md>), [Gradle](<https://devfeed.tech/topics/gradle.md>), [Code](<https://devfeed.tech/topics/code.md>), [modules](<https://devfeed.tech/topics/modules.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [build](<https://devfeed.tech/tags/build.md>), [c](<https://devfeed.tech/tags/c.md>), [code](<https://devfeed.tech/tags/code.md>), [gradle](<https://devfeed.tech/tags/gradle.md>), [java](<https://devfeed.tech/tags/java.md>), [module](<https://devfeed.tech/tags/module.md>), [native](<https://devfeed.tech/tags/native.md>)

## AI overview

This practical tutorial examines the incubating Foreign Linker API from JEP-389 in JDK 16 by connecting Java code to the native libsodium library. It demonstrates experimentation in jshell, project configuration with Gradle, module and runtime options, and mapping C types and native memory layouts to Java types.

## Source excerpt

JDK 16 is coming and with the incubating JEP-389, let's have a practical look at this API that should supersede JNI.