/r/java
News, Technical discussions, research papers and assorted things of interest related to the Java programming language
NO programming help, NO learning Java related questions, NO installing or downloading Java questions, NO JVM languages - Exclusively Java
These have separate subreddits - see below.
Upvote good content, downvote spam, don't pollute the discussion with things that should be settled in the vote count.
Join us on IRC
freenode.net #reddit-java
With the introduction of the new release cadence, many have asked where they should download Java, and if it is still free. To be clear, YES β Java is still free.
If you would like to download Java for free, you can get OpenJDK builds from the following vendors, among others:
Adoptium (formerly AdoptOpenJDK)
RedHat
Azul
Amazon
SAP
Liberica JDK
Dragonwell JDK
GraalVM (High performance JIT)
Oracle
Microsoft
Some vendors will be supporting releases for longer than six months. If you have any questions, please do not hesitate to ask them!
Learn Programming
Java Help β Seek help here
Learn Java
Java Conference Videos
Java TIL
Java Examples
JavaFX
Oracle
/r/java
I recently saw a tweet that caught my eye.
Now, I get the frustration.
Monoliths can be cumbersome, especially as projects grow. But throwing the baby out with the bathwater? Maybe not so fast.
I believe that modern monoliths can work, especially for certain types of projects. They offer advantages like tight integration, faster development cycles, and easier data sharing.
The key is understanding the trade-offs and using the right tools.
What do you think? Are modern monoliths a relic of the past, or is there still a place for them?
I currently have an application that uses Microsoft's RulesEngine where the rules are hosted as JSON in an external service so that rules can be changed without the need for a code change. I am re-writing the application in Java and wondering if anyone with Java experience has a suggestion for a very similar rules engine that supports JSON. I've looked over a couple and Drool seems like the best candidate, but also quite complex to configure it for my needs.
I know rules engines are quite common, but I really need one that can parse the expressions from JSON. If anyone has any suggestions, I'd really appreciate it!
Minum is a minimalist web framework written in Java, developed over five years by a TDD practitioner of fourteen years experience. Provides an all-in-one foundation for a highly-maintainable single binary web application. For TDD, by TDD.
make test_coverage
)make mutation_test
)This framework enables high-maintainability through minimalism and simplicity. Developers using this framework will achieve the most benefit if they are of a similar mindset. Frameworks like Spring, which provide capabilities as large blocks with high guardrails, offer a different paradigm.
No, I am not saying that. However, there is need for a minimalist web framework. You can build a fully-functioning web application with high sophistication with either Spring or Minum, but Minum is five thousand lines of code and Spring is a million. For quality-oriented long-view practitioners, the benefits of minimalism outweigh its drawbacks.
This is a misunderstanding - Minum is five thousand lines of code - the "minimalist" competitors range from 400,000 to 700,000 lines when accounting for their dependencies. I have not found a similar project.
Easier debugging, maintainability, lower overall cost. Most frameworks trade faster start-up for a higher overall cost. If you need sustainable quality, the software must be well-tested and documented from the onset.
It does not exist - logic-free templating was intentionally chosen. Any logic must be written explicitly as code, which makes maintenance easier.
It currently does not. Those features may be built in the future. The choice was made to minimize scope for now.
β
* Due to the necessities of structuring a web server for test-driven development, some parts of the socket / http handling code had to be written a bit more cleverly than preferred.
Hi all, I am looking for people who have had experiences with Vaadin. Good or bad. I am considering it as an alternative to go Thymeleaf+Spring boot for a personal project.
Having a javafx background, this framework feels more familiar than htmx & thymeleaf on top of Spring boot. And on the plus side, it comes with a couple of ready to use ui components.
Any feedback is appreciated
https://support.apple.com/en-us/109035 has just dropped, which should fix the bug in 14.4 that was causing problems with the JVM's JIT and causing process crashes.
Hey friends,
I am about to propose the complete removal of Windows 32-bit support in OpenJDK following JEP 449, which deprecated-for-removal the support.
This would only impact newer versions of OpenJDK (such as OpenJDK 23 and future).
Let us know if you have a critical use case where you are still upgrading OpenJDK to the latest, on Windows 32 bit environments, and why you have to update OpenJDK, as well as why you can't move to a Windows 64 bit environment.
I've been going down a rabbit hole this weekend reading the OSGi specification.
It's a bit fascinating in the ratio of how confusing it is to internet ink claiming that "no, it's simple really." The extremely salty infoq articles were a great read too.
But for anyone that has experience in OSGi + the dynamic capabilities it has, how do you think that system would have been designed if JPMS modules were in the language from day 1.
I've seen the OSGi connect spec, but even without understanding everything it feels kinda tacked on.
A few weeks ago I posted a link to Coat, a config library I have written.
There u/jeyjeyemem mentioned the performance benchmark he wrote and Coat is now contained in it. Coat 1.0.0 already performed very well. Even though that was not a design goal of Coat there wasn't much missing to raise performance even more. Coat already had all config information on creation time of the config object, but still did the conversion from String to the actual type on each access. This is changed now and Coat performes way faster than before and is now the fastest config library (of the ones in the benchmark).
This change is so big that I even decided to spend a section in the user manual on that topic.
This change requires that the validation of config entries is done on
creating the config object and not afterwards. Therefore the validate()
method was removed and the creation of the object may now throw a
ConfigValidationException
. Since this is a breaking change I took the
opportunity to introduce other small breaking changes. But all of them are easy
to migrate as is explained in the release
notes.
So, if someone is already using that library, sorry for the breaking change so shortly after the last release, but I think the small adaptations are worth it.
I was looking around few open source projects and I found one thing strange. They are implementing their own crc32c. Hadoop, snappy-java, guava...
Even though Java provides of its own.
I just made a quick benchmark and found out that the java's implementation is the quickest.
Can somebody put some light on this.
I am noob and a non native English speaker.
Edit One added question, is there a data structure like bloom filter but with 100% guarantee. Currently I am working on a problem where I have n byte arrays. A bunch of byte arrays will be stored inside files. I want to quickly know if the byte array is present inside that file or not. Currently thinking of including crc32c checksum.
Edit 2 Thanks guys for all the info
Bob is small utility annotation processor that acts as an alternative for Lomboks Builder annotation without byte code magic.
Gradle 8.7 is there bringing support for running Gradle on Java 22 and other things: Gradle 8.7 Release Notes
why is everyone suddenly recommending to use other IDEs for java? I've been using vscode for a while without any issue, and so far it's the easiest and smoothest experience out of all and i prefer it over others like eclipse and intellij
Initiated by the following thread:
https://www.reddit.com/r/java/comments/1bgzyf6/comment/kvwer6o/
Is using AssertJ not just for Junit testing but also for normal program flow a good idea? Like checking if a textfield value is null,empty or not instead of using .equals and the rest?