logoalt Hacker News

hocuspocus • today at 3:21 PM • 2 replies • view on HN

Native images shouldn't be too messy anymore, Oracle put a lot of effort into DX improvements and all major web frameworks are now aware it's an important and growing use case.

Struggling to build native images should be a sign you're reliant on libraries that are dangerously outdated and abandoned.


Replies

jcurtis • today at 4:26 PM

They can definitely be pretty messy in some ways; even the standard library doesn't work out of the box perfectly. I have certainly struggled to get image manipulation with java.awt (e.g. thumbnail generation for a fairly standard web use case) to work in a native image.

emoII • today at 4:50 PM

So it is an antipattern nowadays to manipulate the classpath after building? Iirc native image require static classpath, but it is quite common to inject e.g. environment specific data via the classpath. Should one just read from the filesystem instead, or what’s the strat there?

➕ show 1 reply