<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Anthony Goubard on foojay.io - Friends of OpenJDK</title><link>https://foojayio.github.io/website/today/author/anthony-goubard/</link><description>Articles written by Anthony Goubard on foojay.io - Friends of OpenJDK</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Tue, 09 Dec 2025 08:23:00 +0000</lastBuildDate><atom:link href="https://foojayio.github.io/website/today/author/anthony-goubard/index.xml" rel="self" type="application/rss+xml"/><item><title>Java, What's Old? Part III - I/O</title><link>https://foojayio.github.io/website/today/java-whats-old-part-iii-i-o/</link><pubDate>Tue, 09 Dec 2025 08:23:00 +0000</pubDate><guid>https://foojayio.github.io/website/today/java-whats-old-part-iii-i-o/</guid><description>&lt;p&gt;After Java, &lt;a href="https://foojayio.github.io/website/today/java-whats-old-part-i-collections/"&gt;What&amp;rsquo;s Old? Part I: Collections&lt;/a&gt;
 and &lt;a href="https://foojayio.github.io/website/today/java-whats-old-part-ii-utils/"&gt;Java, What&amp;rsquo;s Old? Part II: Utils&lt;/a&gt;
, let&amp;rsquo;s now have a look at less-known old input/output classes of the JDK that can still be useful.&lt;/p&gt;
&lt;p&gt;Everything in this series will be in Java 8 and later, so after reading this article, you will be able to use it in your projects.&lt;/p&gt;
&lt;h2 id="h2-0-scanner"&gt;Scanner&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://docs.oracle.com/javase/8/docs/api/java/util/Scanner.html" target="_blank" rel="noopener noreferrer"&gt;Scanner&lt;/a&gt;
 is a class in &lt;code&gt;java.util&lt;/code&gt; package that helps you parse files and input stream.&lt;/p&gt;</description></item><item><title>Java, What's Old? Part II: Utils</title><link>https://foojayio.github.io/website/today/java-whats-old-part-ii-utils/</link><pubDate>Wed, 30 Jul 2025 08:48:29 +0000</pubDate><guid>https://foojayio.github.io/website/today/java-whats-old-part-ii-utils/</guid><description>&lt;p&gt;After &lt;a href="https://foojayio.github.io/website/today/java-whats-old-part-i-collections/"&gt;Java, What&amp;rsquo;s Old? Part I - Collections&lt;/a&gt;
, let&amp;rsquo;s now have a look at less known old utility classes that can still be useful.&lt;/p&gt;
&lt;p&gt;Everything in this series will be in Java 8 and later, so after reading this article, you will be able to use it in your projects.&lt;/p&gt;
&lt;h2 id="h2-0-objects"&gt;Objects&lt;/h2&gt;
&lt;p&gt;&lt;a href="https://docs.oracle.com/javase/8/docs/api/java/util/Objects.html" target="_blank" rel="noopener noreferrer"&gt;Objects&lt;/a&gt;
 (with a s) is a utility class from the &lt;code&gt;java.util&lt;/code&gt; package that contains static methods to make your code more readable. Do not confuse it with the &lt;code&gt;Object&lt;/code&gt; (without s) class of the &lt;code&gt;java.lang&lt;/code&gt; package.&lt;/p&gt;</description></item><item><title>Java, What's Old? Part I: Collections</title><link>https://foojayio.github.io/website/today/java-whats-old-part-i-collections/</link><pubDate>Thu, 19 Jun 2025 08:31:52 +0000</pubDate><guid>https://foojayio.github.io/website/today/java-whats-old-part-i-collections/</guid><description>&lt;p&gt;A few weeks ago, I had the honor to present at the &lt;a href="https://www.meetup.com/nl-NL/arnhemjug/" target="_blank" rel="noopener noreferrer"&gt;Arnhem JUG&lt;/a&gt;
 in the Netherlands about &amp;ldquo;Java, What&amp;rsquo;s old?&amp;rdquo; In this series, I&amp;rsquo;m focusing on what&amp;rsquo;s old in the JDK, not that known, and can be useful. A few hidden gems in the JDK.&lt;/p&gt;
&lt;p&gt;Everything in this series is in Java 8 and earlier. So after reading this article, you will be able to use it in your projects.&lt;/p&gt;</description></item><item><title>More Free Shells for your Java IDE</title><link>https://foojayio.github.io/website/today/more-free-shells-for-your-java-ide/</link><pubDate>Tue, 31 Dec 2024 14:30:57 +0000</pubDate><guid>https://foojayio.github.io/website/today/more-free-shells-for-your-java-ide/</guid><description>&lt;p&gt;You may be using one of the terminal applications installed on your operating system or use the included terminal panel of the IDE.&lt;/p&gt;
&lt;p&gt;Not all shells are included in your IDE. Here is a list of shells by default supported for the IDE&amp;rsquo;s based on my &lt;strong&gt;Windows&lt;/strong&gt; computer.&lt;/p&gt;
&lt;p&gt;|&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;ndash;|&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;|&amp;mdash;&amp;mdash;&amp;mdash;|&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;mdash;&amp;ndash;|
| &lt;strong&gt;Shell&lt;/strong&gt; | IntelliJ IDEA | Eclipse | Apache NetBeans |
| Command Prompt | ✅ | ✅ | |
| Powershell | ✅ | | |
| WSL (Windows Subsystem for Linux) | ✅ | ✅ | |
| Git Bash | (1) | ✅ | |
| Cygwin | (1) | | ✅ |
| SSH (Secure SHell) | | ✅ | ✅ |&lt;/p&gt;</description></item><item><title>Foojay Podcast #64: Interviews at JFall about opensource, OpenJDK evolutions, Project Loom, JVM,...</title><link>https://foojayio.github.io/website/today/foojay-podcast-64/</link><pubDate>Mon, 23 Dec 2024 10:51:20 +0000</pubDate><guid>https://foojayio.github.io/website/today/foojay-podcast-64/</guid><description>&lt;p&gt;Let&amp;rsquo;s wrap up this year with more interviews from the JFall conference.&lt;/p&gt;
&lt;p&gt;In this episode you&amp;rsquo;ll learn more about Foojay, JVM internals and writing your own programming language, Project Loom and structured concurrency, learning at conferences, code reviews, creating desktop applications with Java, infrastructure as code, JUG Noord, and much more!&lt;/p&gt;
&lt;h2 id="h2-0-video"&gt;Video&lt;/h2&gt;
&lt;div style="position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;"&gt;
			&lt;iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share; fullscreen" loading="eager" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube.com/embed/kx6DfVE-I0o?autoplay=0&amp;amp;controls=1&amp;amp;end=0&amp;amp;loop=0&amp;amp;mute=0&amp;amp;start=0" style="position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;" title="YouTube video"&gt;&lt;/iframe&gt;
		&lt;/div&gt;

&lt;h2 id="h2-1-podcast-apps"&gt;Podcast Apps&lt;/h2&gt;
&lt;p&gt;You can listen and subscribe to the Foojay Podcast on:&lt;/p&gt;</description></item><item><title>Structured Concurrency is More Than ShutdownOnFailure</title><link>https://foojayio.github.io/website/today/structured-concurrency-is-more-than-shutdownonfailure/</link><pubDate>Thu, 11 Jul 2024 16:34:52 +0000</pubDate><guid>https://foojayio.github.io/website/today/structured-concurrency-is-more-than-shutdownonfailure/</guid><description>&lt;p&gt;&lt;strong&gt;Since Java 21, structured concurrency has been added as a preview feature. Structured concurrency is a way to manage sub-tasks that are run in parallel within a given scope.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;ve ever seen a presentation about &lt;a href="https://docs.oracle.com/en/java/javase/21/core/structured-concurrency.html" target="_blank" rel="noopener noreferrer"&gt;structured concurrency&lt;/a&gt;
, you&amp;rsquo;ve probably seen the use of the &lt;code&gt;ShutdownOnSuccess&lt;/code&gt; or &lt;code&gt;ShutdownOnFailure&lt;/code&gt; classes.&lt;/p&gt;
&lt;p&gt;These classes will stop the scope and the still running sub-tasks within that scope when one of the sub-task succeeds or fails.&lt;/p&gt;</description></item><item><title>Let's Replace the synchronized Keyword</title><link>https://foojayio.github.io/website/today/lets-replace-the-synchronized-keyword/</link><pubDate>Tue, 07 May 2024 04:26:29 +0000</pubDate><guid>https://foojayio.github.io/website/today/lets-replace-the-synchronized-keyword/</guid><description>&lt;p&gt;&lt;strong&gt;Let&amp;rsquo;s see in this article different ways to replace the synchronized keyword to make our code more virtual threads friendly.&lt;/strong&gt;&lt;br&gt;
&lt;img src="https://foojayio.github.io/website/today/lets-replace-the-synchronized-keyword/synchronized-loc.png" alt="" loading="lazy"&gt;
 Lines of code of the different solutions discussed in this article&lt;/p&gt;
&lt;h2 id="h2-0-synchronized-and-pinning-threads"&gt;Synchronized and pinning threads&lt;/h2&gt;
&lt;p&gt;Since Java 21, we can enjoy virtual threads and have more than 1 million threads in Java.&lt;/p&gt;
&lt;p&gt;But it has a condition, the virtual thread shouldn&amp;rsquo;t be pinned to the OS thread.&lt;/p&gt;
&lt;p&gt;Pinning means that a virtual thread is blocking the OS thread from being used by any other virtual threads.&lt;/p&gt;</description></item><item><title>12 Text Tools For Developers</title><link>https://foojayio.github.io/website/today/12-text-tools-for-developers/</link><pubDate>Tue, 09 Apr 2024 07:31:13 +0000</pubDate><guid>https://foojayio.github.io/website/today/12-text-tools-for-developers/</guid><description>&lt;p&gt;&lt;strong&gt;As developer, you would think we would spend all our time in an IDE doing development. The reality is a bit different. We may need to analyze logs, test our web services, generate test data, do security tests, analyze data in the database, and so on. Text processing os also part of a developer job. Let&amp;rsquo;s see a few free text tools to simplify your job.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Using online tools makes me wonder if I&amp;rsquo;m leaking company data to the website, so I wrote a desktop freeware &lt;a href="https://www.japplis.com/toolbox/" target="_blank" rel="noopener noreferrer"&gt;Japplis Toolbox&lt;/a&gt;
 containing a collection of text tools.&lt;/p&gt;</description></item><item><title>foojay – 12 Lessons Learned From Doing The 1BRC Challenge</title><link>https://foojayio.github.io/website/today/12-lessons-learned-from-doing-the-one-billion-row-challenge/</link><pubDate>Thu, 22 Feb 2024 10:44:56 +0000</pubDate><guid>https://foojayio.github.io/website/today/12-lessons-learned-from-doing-the-one-billion-row-challenge/</guid><description>&lt;p&gt;The One Billion Row Challenge or 1BRC or 1️⃣🐝🏎 was a challenge to read a CSV file of one billion rows with &amp;ldquo;station name;temperature&amp;rdquo; data and compute the min/average/max temperature per weather station as fast as possible.&lt;/p&gt;
&lt;p&gt;If you want to know what is the fastest algorithm, you can go the the &lt;a href="https://github.com/gunnarmorling/1brc" target="_blank" rel="noopener noreferrer"&gt;1BRC page&lt;/a&gt;
. But the real answer is &amp;ldquo;&lt;strong&gt;it depends&lt;/strong&gt;&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;It depends:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The machine you&amp;rsquo;re running it on&lt;/li&gt;
&lt;li&gt;How far are you ready to use hacks in your code&lt;/li&gt;
&lt;li&gt;The JVM&lt;/li&gt;
&lt;li&gt;The data in the file&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="h2-0-it-works-on-my-machine"&gt;It works on my machine&lt;/h2&gt;
&lt;p&gt;or to be more precise, it&amp;rsquo;s faster on my machine.&lt;/p&gt;</description></item><item><title>foojay – Sorting Text in Java</title><link>https://foojayio.github.io/website/today/sorting-text-in-java-how-complicated-can-it-be/</link><pubDate>Wed, 07 Feb 2024 08:41:54 +0000</pubDate><guid>https://foojayio.github.io/website/today/sorting-text-in-java-how-complicated-can-it-be/</guid><description>&lt;p&gt;&lt;strong&gt;Sorting text should be easy as String implements the &lt;em&gt;Comparable&lt;/em&gt; interface. In this article, we&amp;rsquo;ll see that it can be more complicated than that.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Text is represented by the &lt;em&gt;String&lt;/em&gt; class in Java. In this article we&amp;rsquo;ll explore how to sort String, the advantages and drawbacks of each possibility.&lt;/p&gt;
&lt;h2 id="h2-0-level-1-comparable"&gt;Level 1: Comparable&lt;/h2&gt;
&lt;p&gt;The class String implements &lt;em&gt;Comparable&lt;/em&gt; so sorting a list of String is as simple as&lt;/p&gt;
&lt;pre class="EnlighterJSRAW" data-enlighter-language="java" data-enlighter-theme="" data-enlighter-highlight="" data-enlighter-linenumbers="" data-enlighter-lineoffset="" data-enlighter-title="" data-enlighter-group=""&gt;List&amp;lt;String&amp;gt; textList = new ArrayList&amp;lt;&amp;gt;(List.of("test","test11","test2","Test4","test3","test5","tést2","test2","3test","testa","test2a","test4a","test2b"));
Collections.sort(textList);&lt;/pre&gt;
&lt;p&gt;=&amp;gt; &lt;strong&gt;[3test, Test4, test, test11, test2, test2, test2a, test2b, test3, test4a, test5, testa, tést2]&lt;/strong&gt;&lt;/p&gt;</description></item><item><title>Live (re)compile, (re)load, (re)execute Java code in 100 LoC</title><link>https://foojayio.github.io/website/today/live-recompile-reload-reexecute-java-code-in-100-loc/</link><pubDate>Wed, 15 Nov 2023 16:22:05 +0000</pubDate><guid>https://foojayio.github.io/website/today/live-recompile-reload-reexecute-java-code-in-100-loc/</guid><description>&lt;p&gt;Writing your first program in Java can have quite a learning curve.&lt;/p&gt;
&lt;p&gt;Java has been trying in recent releases to make it easier to write the &lt;a href="https://openjdk.org/projects/amber/design-notes/on-ramp" target="_blank" rel="noopener noreferrer"&gt;first simple program&lt;/a&gt;
.&lt;/p&gt;
&lt;p&gt;Here are some changes that simplify your first Java program:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="https://openjdk.org/jeps/222" target="_blank" rel="noopener noreferrer"&gt;JEP 222&lt;/a&gt;
: jshell: The Java Shell (Read-Eval-Print Loop) in JDK 9&lt;/li&gt;
&lt;li&gt;&lt;a href="https://openjdk.org/jeps/330" target="_blank" rel="noopener noreferrer"&gt;JEP 330&lt;/a&gt;
: Launch Single-File Source-Code Programs in JDK 11&lt;/li&gt;
&lt;li&gt;&lt;a href="https://openjdk.org/jeps/445" target="_blank" rel="noopener noreferrer"&gt;JEP 445&lt;/a&gt;
: Unnamed Classes and Instance Main Methods in preview in JDK 21&lt;/li&gt;
&lt;li&gt;&lt;a href="https://openjdk.org/jeps/458" target="_blank" rel="noopener noreferrer"&gt;JEP 458&lt;/a&gt;
: Launch Multi-File Source-Code Programs. Not released yet.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In this article, we&amp;rsquo;ll write a program (&lt;strong&gt;The Reloader&lt;/strong&gt;) to easily play with Java code without the need to know how to compile or run the code or print the result.&lt;/p&gt;</description></item><item><title>The Files in JDK 21</title><link>https://foojayio.github.io/website/today/the-files-in-jdk-21/</link><pubDate>Tue, 17 Oct 2023 07:21:32 +0000</pubDate><guid>https://foojayio.github.io/website/today/the-files-in-jdk-21/</guid><description>&lt;p&gt;As Java developers, we all have it installed on our computer: the Java Development Kit, also known as the JDK. I remember putting the first version on a few floppy disks back in 1995. Since then it has grown multiple times. In this article, we&amp;rsquo;ll explore the files of the JDK.&lt;/p&gt;
&lt;p&gt;For this article, Eclipse Temurin &lt;a href="https://foojayio.github.io/website/today/java-21-is-available-today-and-its-quite-the-update/"&gt;JDK 21&lt;/a&gt;
 for Windows has been used.&lt;/p&gt;
&lt;h2 id="h2-0-files"&gt;Files&lt;/h2&gt;
&lt;h3 id="h3-1-the-statistics"&gt;The statistics&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Total size: 325 MB&lt;/li&gt;
&lt;li&gt;Number of files: 572&lt;/li&gt;
&lt;li&gt;Number of files including in zip files: 47,629&lt;/li&gt;
&lt;li&gt;Largest file: lib/modules with 134 MB&lt;/li&gt;
&lt;li&gt;Number of class files: 27,929 (was 27,064 in JDK 20)&lt;/li&gt;
&lt;li&gt;Number of Java files (in src.zip): 15,404 (was 15,044 in JDK 20)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src="https://foojayio.github.io/website/today/the-files-in-jdk-21/jdk21-all-files.png" alt="" loading="lazy"&gt;
&lt;/p&gt;</description></item><item><title>Dissection of Joeffice: Open Source Office Suite in Java</title><link>https://foojayio.github.io/website/today/dissection-of-joeffice-open-source-office-suite-in-java/</link><pubDate>Tue, 11 Jul 2023 09:33:30 +0000</pubDate><guid>https://foojayio.github.io/website/today/dissection-of-joeffice-open-source-office-suite-in-java/</guid><description>&lt;p&gt;10 years ago, I challenged myself to write an office suite in Java in &lt;a href="https://www.youtube.com/watch?v=6oJyaUzkQVM&amp;amp;list=PLsezR6w8oWsJAKvFuv3JI34PLFFMIxLVA" target="_blank" rel="noopener noreferrer"&gt;30 days&lt;/a&gt;
. This is how the first version of &lt;a href="https://www.joeffice.com/" target="_blank" rel="noopener noreferrer"&gt;Joeffice&lt;/a&gt;
 was born. This created quite some buzz, including articles on &lt;a href="https://tech.slashdot.org/story/13/05/26/0418229/java-developer-says-he-built-launched-basic-open-source-office-suite-in-30-days" target="_blank" rel="noopener noreferrer"&gt;Slashdot&lt;/a&gt;
, &lt;a href="https://arstechnica.com/information-technology/2013/06/joeffice-an-open-source-office-suite-one-developer-built-in-30-days/" target="_blank" rel="noopener noreferrer"&gt;Ars Technica&lt;/a&gt;
 and &lt;a href="https://www.pcworld.com/article/452028/java-developer-says-he-built-launched-basic-open-source-office-suite-in-30-days.html" target="_blank" rel="noopener noreferrer"&gt;PC World&lt;/a&gt;
.&lt;/p&gt;
&lt;p&gt;Last month I released a second update. Let&amp;rsquo;s explore how I did this. By levering Java libraries, I was able to create such a complex piece of software very quickly.&lt;/p&gt;</description></item><item><title>Write Once, Run Embedded in any IDE</title><link>https://foojayio.github.io/website/today/write-once-run-embedded-in-any-ide/</link><pubDate>Tue, 16 May 2023 13:34:19 +0000</pubDate><guid>https://foojayio.github.io/website/today/write-once-run-embedded-in-any-ide/</guid><description>&lt;p&gt;&lt;a href="https://foojayio.github.io/website/time-zones.png"&gt;&lt;img src="https://foojayio.github.io/website/today/write-once-run-embedded-in-any-ide/time-zones-1024x192.png" alt="Same Time Zones application running in IntelliJ IDEA, Eclipse and NetBeans" title="Same application running in IntelliJ IDEA, Eclipse and NetBeans" loading="lazy"&gt;
&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Having written many Java GUI applications, I thought it would be cool to run them embedded in IntelliJ IDEA, Eclipse and NetBeans. I didn&amp;rsquo;t want to write three plugins per application so I came up with this solution.&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id="h2-0-the-embedded-panel-criteria"&gt;The embedded panel criteria&lt;/h2&gt;
&lt;p&gt;To convert my Java Swing applications to run embedded in an IDE, I had to put the user interface in a panel with minimal implementation changes. I came up with these &lt;em&gt;should ideally&lt;/em&gt; criteria:&lt;/p&gt;</description></item></channel></rss>