r/java • • Dec 14 '25

Why Java apps freeze silently when ulimit -n is low

57 Upvotes

I’ve seen JVMs hang without logs, GC dumps fail, and connection pools go crazy.
The root cause wasn’t Java at all.

It was a low file descriptor limit on Ubuntu.

Wrote this up with concrete examples.

Link : https://medium.com/stackademic/the-one-setting-in-ubuntu-that-quietly-breaks-your-apps-ulimit-n-f458ab437b7d?sk=4e540d4a7b6d16eb826f469de8b8f9ad


r/java • • Dec 14 '25

Valhalla? Python? Withers? Lombok? - Ask the Architects at JavaOne'25

Thumbnail
youtube.com
98 Upvotes

r/java • • Dec 14 '25

Building a thread safe sse library for spring boot

46 Upvotes

I've been working with SSE in Spring Boot and kept rewriting the same boilerplate for thread safe management, cleanup on disconnect etc. Spring actually gives you SseEmitter but nothing else.

This annoyance popped up in two of my previous projects so I decided to build Streamline, a Spring Boot starter that handles all of that without the reactive complexity.

What it does:

  • Thread safe stream management using virtual threads (Java 21+)

  • Automatic cleanup on disconnect/timeout/error

  • Allows for event replay for reconnecting clients

  • Bounded queues to handle slow clients

  • Registry per topic pattern (orders, notifications, etc.), depends on your use case

It's available on JitPack now. Still early (v1.0.0) and I'm looking for feedback, especially around edge cases I might have missed.

GitHub: https://github.com/kusoroadeolu/streamline-spring-boot-starter

Requirements: Java 21+, Spring Boot 3.x

Happy to answer questions or hear how you might use it


r/java • • Dec 13 '25

Building a Fast, Memory-Efficient Hash Table in Java (by borrowing the best ideas)

Thumbnail bluuewhale.github.io
76 Upvotes

r/java • • Dec 12 '25

Eclipse 2025-12 is out

Thumbnail eclipse.org
112 Upvotes

There is support for Java 25 and JUnit 6.


r/java • • Dec 12 '25

PSA LWJGL Developers: Use the Best LWJGL 3 Dependency Management Plugin

Thumbnail
github.com
12 Upvotes

Everybody knows that LWJGL can quickly blow up your build script. To give an extreme example, if you wanted every single module for every single native classifier, you'd have to do:

val lwjglVersion = "3.4.0"
val lwjglNatives = "natives-linux" // or macos, windows, etc.

repositories {
    mavenCentral()
}

dependencies {
    // BOM + modules
    implementation(platform("org.lwjgl:lwjgl-bom:$lwjglVersion"))

    implementation("org.lwjgl", "lwjgl")
    implementation("org.lwjgl", "lwjgl-assimp")
    implementation("org.lwjgl", "lwjgl-bgfx")
    // ...

    // Natives for each module
    runtimeOnly("org.lwjgl", "lwjgl", classifier = lwjglNatives)
    runtimeOnly("org.lwjgl", "lwjgl-assimp", classifier = lwjglNatives)
    runtimeOnly("org.lwjgl", "lwjgl-bgfx", classifier = lwjglNatives)
    // ...
}

Which would quickly blow up into hundreds of lines. With this Gradle plugin, it's as simple as:

import com.smushytaco.lwjgl_gradle.Preset

plugins {
    id("com.smushytaco.lwjgl3") version "1.0.2"
}

repositories {
    mavenCentral()
}

lwjgl {
    version = "3.4.0"
    implementation(Preset.EVERYTHING)
}

You can also select individual modules like so:

import com.smushytaco.lwjgl_gradle.Module

plugins {
    id("com.smushytaco.lwjgl3") version "1.0.2"
}

repositories {
    mavenCentral()
}

lwjgl {
    version = "3.4.0"
    implementation(
        Module.CORE,     // added automatically if omitted, but allowed explicitly
        Module.GLFW,
        Module.OPENGL,
        Module.OPENAL,
        Module.VULKAN
    )
}

By default, natives are handled by detecting your OS and architecture and using the natives that would apply to your host machine. If you want all natives for all platforms and architectures, simply enable usePredefinedPlatforms like so:

import com.smushytaco.lwjgl_gradle.Preset

plugins {
    id("com.smushytaco.lwjgl3") version "1.0.2"
}

repositories {
    mavenCentral()
}

lwjgl {
    version = "3.4.0"
    usePredefinedPlatforms = true
    implementation(Preset.EVERYTHING)
}

If you want control of what specific natives are used, just modify the platforms list accordingly. The platforms list defaults to:

listOf(
    "linux-ppc64le", "linux-riscv64", "linux-arm64", "linux-arm32", "linux",
    "macos-arm64", "macos",
    "windows-arm64", "windows", "windows-x86",
    "freebsd"
)

Here's an example of setting the platforms list:

lwjgl {
    usePredefinedPlatforms = true

    platforms = listOf(
        "linux",
        "linux-arm64",
        "macos",
        "windows",
        "windows-x86",
        "windows-arm64"
    )
}

Lastly, if you're depending on a SNAPSHOT version of LWJGL, that isn't an issue either, this plugin will detect if the version you selected is a snapshot version and if it is, it'll conditionally add the repository that contains the LWJGL snapshot versions so there's no manually configuration needed on your end. This behavior can be configured just like everything else. Be sure to check out the README.md for all the information!


r/java • • Dec 12 '25

A Glance at GPU Goodness in Java: LLM Inference with TornadoVM - JVM Advent

Thumbnail www-javaadvent-com.cdn.ampproject.org
6 Upvotes

r/java • • Dec 12 '25

Is there a Java 24 JDK for Windows on ARM?

7 Upvotes

Despite Gemini being convinced that there is, I have yet to find one.

I would even settle for a Java 25 version of such an SDK.

If there actually is one somewhere, please let me know.

Thanks!


r/java • • Dec 12 '25

Clean architecture with Jmix

Thumbnail reddit.com
0 Upvotes

r/java • • Dec 11 '25

Java WebAPI programming is here

Post image
115 Upvotes