Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 950962

Summary: app-misc/elasticsearch-8.17.3 fails to start: java.lang.module.FindException: Module jdk.attach not found, required by org.elasticsearch.entitlement
Product: Gentoo Linux Reporter: nebojsa <nebojsa>
Component: Current packagesAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: UNCONFIRMED ---    
Severity: normal CC: gentoo, nebojsa
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Depend on jdk insted of on jre

Description nebojsa 2025-03-08 23:39:17 UTC
elasticsearch-8.17 introduced dependency on jdk. Without a jdk installed, it fails to start complaining about jdk.attach module not found.
After installing virtual/jdk:17, it works without a problem

Reproducible: Always
Comment 1 nebojsa 2025-03-08 23:41:20 UTC
Created attachment 920379 [details, diff]
Depend on jdk insted of on jre
Comment 2 Volkmar W. Pogatzki 2025-03-09 07:06:56 UTC
(In reply to nebojsa from comment #0)
> elasticsearch-8.17 introduced dependency on jdk. Without a jdk installed, it
> fails to start complaining about jdk.attach module not found.
> After installing virtual/jdk:17, it works without a problem
> 
> Reproducible: Always

Usually if using virtual/jdk, it should go in DEPEND according to https://wiki.gentoo.org/wiki/Java_Developer_Guide#JDK.2FJRE.
In RDEPEND you put virtual/jre - and don't forget to inherit either of 
java-pkg-2.eclass of java-pkg-opt-2.eclass.