<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>A N M Bazlur Rahman on foojay.io - Friends Of OpenJDK</title><link>https://foojay.io/today/author/bazlur-rahman/</link><description>Articles written by A N M Bazlur Rahman on foojay.io - Friends Of OpenJDK</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 20 Feb 2026 17:48:21 +0000</lastBuildDate><atom:link href="https://foojay.io/today/author/bazlur-rahman/index.xml" rel="self" type="application/rss+xml"/><item><title>A Visual Diff of Java’s Evolution: Inside java.evolved</title><link>https://foojay.io/today/a-visual-diff-of-javas-evolution-inside-java-evolved/</link><pubDate>Fri, 20 Feb 2026 17:48:21 +0000</pubDate><guid>https://foojay.io/today/a-visual-diff-of-javas-evolution-inside-java-evolved/</guid><description>&lt;p&gt;A community project called &lt;a href="https://javaevolved.github.io/" target="_blank" rel="noopener noreferrer"&gt;&lt;strong&gt;java.evolved&lt;/strong&gt;&lt;/a&gt; was recently launched to document how common Java coding patterns have changed across releases. Instead of explaining features in isolation, the site presents &amp;ldquo;before and after&amp;rdquo; examples: traditional idioms next to modern alternatives.&lt;/p&gt;&#10;&lt;p&gt;The approach targets a practical problem. Most developers work in mixed-era codebases where Java 6, 8, and 17 styles coexist. Rather than memorizing new language features, the site shows what existing code would look like if written today.&#10;&lt;img src="https://foojay.io/today/a-visual-diff-of-javas-evolution-inside-java-evolved/Screenshot-2026-02-20-at-6.28.07-AM-700x446.png" alt="" width="700" height="446" loading="lazy" decoding="async"&gt;&lt;/p&gt;</description></item><item><title>Announcing: Sustainability for Java Developers</title><link>https://foojay.io/today/announcing-sustainability-for-java-developers-a-new-collaborative-guide-from-the-foojay-io-community/</link><pubDate>Mon, 02 Feb 2026 11:04:54 +0000</pubDate><guid>https://foojay.io/today/announcing-sustainability-for-java-developers-a-new-collaborative-guide-from-the-foojay-io-community/</guid><description>&lt;p&gt;Java developers from around the world are writing a book about a question that&amp;rsquo;s becoming impossible to ignore: how do we write software that&amp;rsquo;s good for both our projects and the planet?&lt;/p&gt;&#10;&lt;p&gt;&lt;em&gt;Sustainability for Java Developers: Towards an Understanding of Sustainable Java Software Development&lt;/em&gt; is now freely available on Leanpub, bringing together Java Champions, architects, and technical writers to look at sustainability from every angle.&lt;/p&gt;&#10;&lt;figure class="size-large is-resized"&gt;&#10; &lt;img src="https://foojay.io/today/announcing-sustainability-for-java-developers-a-new-collaborative-guide-from-the-foojay-io-community/sustainabilitybook-793x1024.jpg" alt="" width="793" height="1024" style="width:277px;height:auto" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;The book covers everything from the environmental footprint of our data centers to the ethics of open source supply chains, from efficient data formats to the often-overlooked topic of career longevity.&lt;/p&gt;</description></item><item><title>AI Applications with LangChain4j Guardrails and Spring Boot</title><link>https://foojay.io/today/building-robust-ai-applications-with-langchain4j-guardrails-and-spring-boot/</link><pubDate>Tue, 29 Jul 2025 11:16:31 +0000</pubDate><guid>https://foojay.io/today/building-robust-ai-applications-with-langchain4j-guardrails-and-spring-boot/</guid><description>&lt;p&gt;&lt;strong&gt;As AI applications become increasingly complex, ensuring that language models behave predictably and safely is paramount. LangChain4j&amp;rsquo;s guardrails feature provides a powerful framework for validating both the inputs and outputs of your AI services.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;This article demonstrates how to implement comprehensive guardrails in a Spring Boot application, with practical examples that you can adapt to your use cases.&lt;/p&gt;&#10;&lt;blockquote&gt;&#10;&lt;p&gt;📦 &lt;strong&gt;Complete source code available at&lt;/strong&gt; : &lt;a href="https://github.com/rokon12/guardrails-demo" target="_blank" rel="noopener noreferrer"&gt;github.com/rokon12/guardrails-demo&lt;/a&gt;&lt;/p&gt;&#10;&lt;/blockquote&gt;&#10;&lt;h2 id="understanding-langchain4j-guardrails"&gt;Understanding LangChain4j Guardrails&lt;/h2&gt;&#10;&lt;p&gt;In LangChain4j, guardrails are validation mechanisms that operate exclusively on AI Services, the framework&amp;rsquo;s high-level abstraction for interacting with language models. Unlike simple validators, guardrails provide sophisticated control over the entire AI interaction lifecycle.&lt;/p&gt;</description></item><item><title>Java’s Structured Concurrency: Finally Finding Its Footing</title><link>https://foojay.io/today/javas-structured-concurrency-finally-finding-its-footing/</link><pubDate>Wed, 04 Jun 2025 12:21:07 +0000</pubDate><guid>https://foojay.io/today/javas-structured-concurrency-finally-finding-its-footing/</guid><description>&lt;p&gt;The structured concurrency API changed again after two incubations and four rounds of previews.&lt;/p&gt;&#10;&lt;p&gt;Ideally, this scenario is unexpected.&lt;/p&gt;&#10;&lt;p&gt;However, given its status as a preview API, such changes can occur, as was the case here.&lt;/p&gt;&#10;&lt;p&gt;These changes lend considerable maturity to the API, and I am hopeful it will now stabilize without requiring further modifications.&lt;/p&gt;&#10;&lt;h3 id="what-actually-changed-this-time"&gt;&lt;strong&gt;What Actually Changed This Time&lt;/strong&gt;&lt;/h3&gt;&#10;&lt;p&gt;When I first started working with structured concurrency back in its incubation phase, I was excited about the promise of cleaner concurrent code.&lt;/p&gt;</description></item><item><title>Building FormPilot</title><link>https://foojay.io/today/building-formpilot-my-journey-creating-an-ai-powered-form-filler-with-rag-langchain4j-and-ollama/</link><pubDate>Tue, 06 May 2025 10:00:04 +0000</pubDate><guid>https://foojay.io/today/building-formpilot-my-journey-creating-an-ai-powered-form-filler-with-rag-langchain4j-and-ollama/</guid><description>&lt;blockquote&gt;&#10;&lt;p&gt;&lt;strong&gt;Disclaimer: This article details an experimental project built for learning and demonstration purposes. The implementation described is not intended as production-grade solution. Some parts of the code were generated using JetBrains&amp;rsquo; AI Agent, &lt;a href="https://www.jetbrains.com/junie/" target="_blank" rel="noopener noreferrer"&gt;Junie&lt;/a&gt;.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;/blockquote&gt;&#10;&lt;p&gt;Have you ever found yourself filling out the same information on web forms over and over again? Name, email, address, phone number&amp;hellip; it&amp;rsquo;s tedious and time-consuming. As a developer who values efficiency, I decided to tackle this problem head-on by building FormPilot, an intelligent form filler that leverages the power of Large Language Models (LLMs) to fill out forms with contextually appropriate information automatically.&lt;/p&gt;</description></item><item><title>Enhancing LLM’s Conversations with Efficient Summarization</title><link>https://foojay.io/today/summarizingtokenwindowchatmemory-enhancing-llms-conversations-with-efficient-summarization/</link><pubDate>Mon, 03 Mar 2025 13:16:21 +0000</pubDate><guid>https://foojay.io/today/summarizingtokenwindowchatmemory-enhancing-llms-conversations-with-efficient-summarization/</guid><description>&lt;p&gt;&lt;strong&gt;LLM chat models have become an integral part of many applications today. We are all experimenting and exploring the best ways to utilize them effectively. For Java developers, LangChain4j has been an incredible tool in this journey.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;By design, most available APIs, such as ChatGPT and Gemini, operate in a &lt;strong&gt;fire-and-forget&lt;/strong&gt; mode. They don&amp;rsquo;t retain previous interactions, meaning every request is treated as a completely new one.&lt;/p&gt;&#10;&lt;p&gt;However, for a smooth and engaging conversation, maintaining context is crucial&amp;mdash;otherwise, the interaction becomes disjointed and frustrating. The common solution is to pass previous messages along with each new prompt, allowing the LLM to infer context. This is where the &lt;strong&gt;chat memory&lt;/strong&gt; concept comes in.&lt;/p&gt;</description></item><item><title>Java Tips # 01 -  Writing Shebang Scripts in Pure Java</title><link>https://foojay.io/today/java-tips-01-writing-shebang-scripts-in-pure-java/</link><pubDate>Tue, 29 Oct 2024 17:06:37 +0000</pubDate><guid>https://foojay.io/today/java-tips-01-writing-shebang-scripts-in-pure-java/</guid><description>&lt;p&gt;&lt;strong&gt;Did you know you can write a CLI script in Java just as easily as you would in a bash script, and run it directly from the shell?&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;This is commonly called a shebang script, though we are mostly familiar with writing them in bash. Bash scripts are great, but they can be obscure to developers who aren&amp;rsquo;t familiar with the syntax. As a Java developer, you&amp;rsquo;d likely prefer to get things done the Java way. Well, since Java 11, you can do exactly that!&lt;/p&gt;</description></item><item><title>Interview with a Java Champion: Reflections on a Storied Career and Insights for the Next Generation</title><link>https://foojay.io/today/interview-with-a-java-champion-reflections-on-a-storied-career-and-insights-for-the-next-generation/</link><pubDate>Mon, 19 Aug 2024 07:52:18 +0000</pubDate><guid>https://foojay.io/today/interview-with-a-java-champion-reflections-on-a-storied-career-and-insights-for-the-next-generation/</guid><description>&lt;h3 id="introduction"&gt;&lt;strong&gt;Introduction:&lt;/strong&gt;&lt;/h3&gt;&#10;&lt;figure class="alignleft"&gt;&#10; &lt;img src="https://media.licdn.com/dms/image/v2/C4E03AQHOSJQsBSmS3A/profile-displayphoto-shrink_800_800/profile-displayphoto-shrink_800_800/0/1517742324318?e=1729123200&amp;amp;v=beta&amp;amp;t=jVizFMHohUoyR_Jp1Cgi5UO-0lVIMQO2fRu3ivz1LHk" alt="" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;In the fast-paced world of software development, a few individuals leave a lasting impact through their dedication and contributions. Our guest today is a seasoned developer, a respected author, and a cornerstone of the Java community.&lt;/p&gt;&#10;&lt;p&gt;With over two decades of experience, he has played a key role in the evolution of Java from a niche language to a critical tool in various industries. In this interview, he shares his journey, insights, and advice for developers at all stages of their careers.&lt;/p&gt;</description></item><item><title>Creating a Command Line Tool with JBang and PicoCLI to Generate Release Notes</title><link>https://foojay.io/today/creating-a-command-line-tool-with-jbang-and-picocli-to-generate-release-notes/</link><pubDate>Wed, 24 Jul 2024 09:44:36 +0000</pubDate><guid>https://foojay.io/today/creating-a-command-line-tool-with-jbang-and-picocli-to-generate-release-notes/</guid><description>&lt;p&gt;Lately, I have been playing with JBang and PicoCLI, and I am pretty amazed at what we can do with these tools. I needed to create a script that would go to a specified repository on GitHub, check the commit range, and verify if any tickets were associated with them. Additionally, I wanted to check if the ticket is accepted and if the commit was approved or not. The idea was to integrate this script along with the CI/CD pipeline.&lt;/p&gt;</description></item><item><title>Java's Unsafe is Finally Going Away</title><link>https://foojay.io/today/unsafe-is-finally-going-away-embracing-safer-memory-access-with-jep-471/</link><pubDate>Thu, 11 Jul 2024 07:52:32 +0000</pubDate><guid>https://foojay.io/today/unsafe-is-finally-going-away-embracing-safer-memory-access-with-jep-471/</guid><description>&lt;p&gt;Java, being a safe language, doesn&amp;rsquo;t usually allow direct low-level access. Memory is primarily managed on the heap, so developers don&amp;rsquo;t typically deal with memory directly. However, library developers are occasionally required to manipulate memory outside the heap for performance or specific use cases. This is where the controversial &lt;a href="https://github.com/openjdk/jdk/blob/master/src/jdk.unsupported/share/classes/sun/misc/Unsafe.java" target="_blank" rel="noopener noreferrer"&gt;&lt;strong&gt;sun.misc.Unsafe&lt;/strong&gt;&lt;/a&gt; comes in.&lt;/p&gt;&#10;&lt;p&gt;While undeniably powerful, &lt;strong&gt;sun.misc.Unsafe&lt;/strong&gt; is a double-edged sword. Its improper use can lead to severe consequences, including memory leaks, crashes due to invalid memory access, and even security vulnerabilities like buffer overflows. As the name suggests, it&amp;rsquo;s inherently unsafe.&lt;/p&gt;</description></item><item><title>Exploring New Features in JDK 23: Simplifying Java with Module Import Declarations with JEP 476</title><link>https://foojay.io/today/exploring-new-features-in-jdk-23-simplifying-java-with-module-import-declarations-with-jep-476/</link><pubDate>Thu, 20 Jun 2024 16:14:08 +0000</pubDate><guid>https://foojay.io/today/exploring-new-features-in-jdk-23-simplifying-java-with-module-import-declarations-with-jep-476/</guid><description>&lt;p&gt;As Java evolves, simplifying code and improving developer productivity remain priorities.&lt;/p&gt;&#10;&lt;p&gt;&lt;a href="https://openjdk.org/jeps/476" target="_blank" rel="noopener noreferrer"&gt;JEP 476&lt;/a&gt; introduces a new feature in JDK 23: Module Import Declarations.&lt;/p&gt;&#10;&lt;p&gt;This feature aims to streamline the process of importing multiple packages from a module, enhancing code readability and reducing boilerplate.&lt;/p&gt;&#10;&lt;h3 id="what-is-jep-476"&gt;&lt;strong&gt;What is JEP 476?&lt;/strong&gt;&lt;/h3&gt;&#10;&lt;p&gt;JEP 476 proposes the ability to import all packages exported by a module with a single declaration. This is particularly useful for developers who frequently use multiple packages from the same module, as it eliminates the need for numerous individual import statements.&lt;/p&gt;</description></item><item><title>Exploring New Features in JDK 23: Simplifying Java with Primitive Type Patterns with JEP 455</title><link>https://foojay.io/today/exploring-new-features-in-jdk-23-simplifying-java-with-primitive-type-patterns-with-jep-455/</link><pubDate>Thu, 06 Jun 2024 10:37:33 +0000</pubDate><guid>https://foojay.io/today/exploring-new-features-in-jdk-23-simplifying-java-with-primitive-type-patterns-with-jep-455/</guid><description>&lt;p&gt;&lt;strong&gt;Java continues to evolve, introducing features that streamline coding practices and improve readability. &lt;a href="https://openjdk.org/jeps/455" target="_blank" rel="noopener noreferrer"&gt;JEP 455&lt;/a&gt; is one such proposal that enhances the switch statement, making it more versatile and expressive.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;This article delves into how JEP 455 can be utilized to handle complex decision-making scenarios more efficiently. We&amp;rsquo;ll examine a practical example to illustrate the benefits of this feature.&lt;/p&gt;&#10;&lt;h3 id="what"&gt;&lt;strong&gt;What&amp;rsquo;s New in JEP 455?&lt;/strong&gt;&lt;/h3&gt;&#10;&lt;p&gt;This JEP introduces the following key features:&lt;/p&gt;</description></item><item><title>Records for Cleaner and More Expressive Parameterized Tests in JUnit 5</title><link>https://foojay.io/today/records-for-cleaner-and-more-expressive-parameterized-tests-in-junit-5/</link><pubDate>Wed, 03 Apr 2024 09:00:38 +0000</pubDate><guid>https://foojay.io/today/records-for-cleaner-and-more-expressive-parameterized-tests-in-junit-5/</guid><description>&lt;h3 id="introduction"&gt;&lt;strong&gt;Introduction&lt;/strong&gt;:&lt;/h3&gt;&#10;&lt;p&gt;Parameterized testing in JUnit 5 is a potent technique for executing the same test logic with various inputs. While you can use a variety of data structures, such as custom classes, arrays, or collections, Java records offer a compelling advantage in readability, type safety, and expressiveness.&lt;/p&gt;&#10;&lt;p&gt;Let&amp;rsquo;s examine how to leverage Java records for parameterized tests through a concrete example – testing an expression evaluator.&lt;/p&gt;&#10;&lt;h3 id="the-expression-evaluator-scenario"&gt;The Expression Evaluator Scenario&lt;/h3&gt;&#10;&lt;p&gt;Consider a simple expression evaluator capable of handling the following:&lt;/p&gt;</description></item><item><title>Journey of a Java Champion: Bert Jan Schrijver's Path to Mastery and Community Leadership</title><link>https://foojay.io/today/journey-of-a-java-champion-bert-jan-schrijvers-path-to-mastery-and-community-leadership/</link><pubDate>Wed, 10 Jan 2024 15:50:26 +0000</pubDate><guid>https://foojay.io/today/journey-of-a-java-champion-bert-jan-schrijvers-path-to-mastery-and-community-leadership/</guid><description>&lt;figure class="alignright size-full"&gt;&#10; &lt;img src="https://foojay.io/today/journey-of-a-java-champion-bert-jan-schrijvers-path-to-mastery-and-community-leadership/image.jpg" alt="" width="400" height="400" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;Bert Jan is CTO at &lt;a href="https://www.openvalue.eu/" target="_blank" rel="noopener noreferrer"&gt;OpenValue&lt;/a&gt; and focuses on Java, software architecture, Continuous Delivery and DevOps.&lt;/p&gt;&#10;&lt;p&gt;Bert Jan is a Java Champion, JavaOne Rock Star speaker, Duke&amp;rsquo;s Choice Award winner and leads NLJUG, the Dutch Java User Group.&lt;/p&gt;&#10;&lt;p&gt;He loves to share his experience by speaking at conferences, writing for the Dutch Java magazine and helping out Devoxx4Kids by teaching kids how to code. Bert Jan is easily reachable on Twitter at &lt;a href="https://twitter.com/bjschrijver" target="_blank" rel="noopener noreferrer"&gt;@bjschrijver&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Diagnose and Mitigate Pinning in Java's Virtual Thread Execution</title><link>https://foojay.io/today/how-to-diagnose-and-mitigate-pinning-in-javas-virtual-thread-execution/</link><pubDate>Tue, 10 Oct 2023 09:08:10 +0000</pubDate><guid>https://foojay.io/today/how-to-diagnose-and-mitigate-pinning-in-javas-virtual-thread-execution/</guid><description>&lt;p&gt;&lt;strong&gt;In &lt;a href="https://foojay.io/today/web-crawling-in-java-a-tale-of-classical-threads-and-virtual-threads/"&gt;our last article&lt;/a&gt;, we highlighted the impressive performance gains achieved through the use of virtual threads. However, upon diving deeper into the code, we discovered an issue caused by the jsoup library: a phenomenon known as pinning. But before we delve into solutions, let&amp;rsquo;s take a moment to understand what pinning actually is.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;h2 id="what-is-pinning"&gt;What is Pinning?&lt;/h2&gt;&#10;&lt;p&gt;In the context of virtual threads, pinning refers to the condition where a virtual thread is &amp;ldquo;stuck&amp;rdquo; to its carrier thread (the platform thread on which it runs).&lt;/p&gt;</description></item><item><title>Web Crawling in Java: Classical Threads and Virtual Threads</title><link>https://foojay.io/today/web-crawling-in-java-a-tale-of-classical-threads-and-virtual-threads/</link><pubDate>Fri, 29 Sep 2023 12:23:48 +0000</pubDate><guid>https://foojay.io/today/web-crawling-in-java-a-tale-of-classical-threads-and-virtual-threads/</guid><description>&lt;p&gt;I&lt;strong&gt;n today&amp;rsquo;s fast-paced digital world, web crawling is a cornerstone technology behind search engines, data analysis tools, and various other applications.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;&lt;strong&gt;Java, a language known for its robustness and scalability, offers intriguing ways to implement web crawling.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;&lt;strong&gt;Yet, the thread model you choose can make a world of difference.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;&lt;strong&gt;This article unfolds a compelling narrative around web crawling in Java, contrasting classical threads with their newer counterpart: virtual threads.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;h2 id="environment-setup"&gt;&lt;strong&gt;Environment Setup&lt;/strong&gt;&lt;/h2&gt;&#10;&lt;p&gt;Before diving into the code and its intricate comparisons, ensure you have JDK 21 installed on your system. If you&amp;rsquo;re using a Unix-based system, SDKMAN! It makes this simple. Just open your terminal and run &lt;code&gt;curl -s &amp;quot;https://get.sdkman.io&amp;quot; | bash&lt;/code&gt; to install SDKMAN!, followed by &lt;code&gt;source &amp;quot;$HOME/.sdkman/bin/sdkman-init.sh&amp;quot;&lt;/code&gt; to initialize it. Finally, install JDK 21 with &lt;code&gt;sdk install java 21.0.0-&amp;lt;vendor&amp;gt;&lt;/code&gt;, replacing &amp;lt;vendor&amp;gt; with your preferred vendor (e.g., zulu, adopt).&lt;/p&gt;</description></item><item><title>Exploring the Impact of Stack Size on JVM Thread Creation: A Myth Debunked</title><link>https://foojay.io/today/exploring-the-impact-of-stack-size-on-jvm-thread-creation-a-myth-debunked/</link><pubDate>Wed, 20 Sep 2023 06:59:31 +0000</pubDate><guid>https://foojay.io/today/exploring-the-impact-of-stack-size-on-jvm-thread-creation-a-myth-debunked/</guid><description>&lt;p&gt;&lt;strong&gt;Among Java developers, a prevailing assumption is that the number of native threads that can be created within the Java Virtual Machine (JVM) is linked to the stack size. To scrutinize this widespread notion, an experiment was conducted. The results revealed that stack size plays a less significant role in native thread creation than previously thought.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;h2 id="the-experiment"&gt;&lt;strong&gt;The Experiment&lt;/strong&gt;&lt;/h2&gt;&#10;&lt;p&gt;The experiment utilized the following Java program, which continuously creates threads and counts them using an &lt;a href="https://download.java.net/java/early_access/jdk21/docs/api/java.base/java/util/concurrent/atomic/AtomicInteger.html" target="_blank" rel="noopener noreferrer"&gt;AtomicInteger&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>A Look at Sealed Classes, Pattern Matching, Functional Paradigms</title><link>https://foojay.io/today/embracing-modernity-a-comprehensive-look-at-sealed-classes-pattern-matching-and-functional-paradigms-in-java/</link><pubDate>Mon, 11 Sep 2023 08:42:17 +0000</pubDate><guid>https://foojay.io/today/embracing-modernity-a-comprehensive-look-at-sealed-classes-pattern-matching-and-functional-paradigms-in-java/</guid><description>&lt;h3 id="introduction"&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/h3&gt;&#10;&lt;p&gt;The introduction of Sealed Classes in Java and the combination with pattern matching in switch statements has sparked a debate among software developers.&lt;/p&gt;&#10;&lt;p&gt;The argument in question raises concerns about the real-life use cases for Sealed Classes and suggests that pattern matching with switch might promote poor coding practices.&lt;/p&gt;&#10;&lt;p&gt;This article aims to counter these assertions by examining the principles and practical applications of Sealed Classes and pattern matching.&lt;/p&gt;</description></item><item><title>Unlocking Java Wisdom: A Conversation with Oracle ACE Simon Martinelli</title><link>https://foojay.io/today/unlocking-java-wisdom-a-conversation-with-oracle-ace-simon-martinelli/</link><pubDate>Fri, 01 Sep 2023 16:00:01 +0000</pubDate><guid>https://foojay.io/today/unlocking-java-wisdom-a-conversation-with-oracle-ace-simon-martinelli/</guid><description>&lt;figure class="alignright size-full"&gt;&#10; &lt;img src="https://foojay.io/today/unlocking-java-wisdom-a-conversation-with-oracle-ace-simon-martinelli/image-2.jpg" alt="" width="460" height="460" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;In a recent insightful interview, Simon Martinelli, an Oracle ACE associate and veteran Java developer, shares his career experiences, software development philosophies, and views on mentoring. With over two decades in the industry, Martinelli offers a perspective that combines the wisdom of experience with a focus on simplicity and constant learning.&lt;/p&gt;&#10;&lt;h2 id="profiles"&gt;Profiles:&lt;/h2&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;🌍 Homepage:&lt;a href="https://martinelli.ch/" target="_blank" rel="noopener noreferrer"&gt;martinelli.ch&lt;/a&gt;&lt;/li&gt;&#10;&lt;li&gt;👔 LinkedIn:&lt;a href="https://www.linkedin.com/in/simonmartinelli/?originalSubdomain=ch" target="_blank" rel="noopener noreferrer"&gt;Simon Martinelli on LinkedIn&lt;/a&gt;&lt;/li&gt;&#10;&lt;li&gt;🐦 Twitter:&lt;a href="https://twitter.com/simas_ch" target="_blank" rel="noopener noreferrer"&gt;@simas_ch on Twitter&lt;/a&gt;&lt;/li&gt;&#10;&lt;li&gt;📦 GitHub:&lt;a href="https://github.com/simasch" target="_blank" rel="noopener noreferrer"&gt;simasch on GitHub&lt;/a&gt;&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="fun-fact"&gt;Fun Fact:&lt;/h2&gt;&#10;&lt;blockquote&gt;&#10;&lt;p&gt;Before starting my IT career, I was working as a traffic controller at Swiss Railways.&lt;/p&gt;</description></item><item><title>Testable Code: A Journey Through Consideration and Refactoring</title><link>https://foojay.io/today/writing-testable-code-a-journey-through-consideration-and-refactoring/</link><pubDate>Wed, 30 Aug 2023 06:47:47 +0000</pubDate><guid>https://foojay.io/today/writing-testable-code-a-journey-through-consideration-and-refactoring/</guid><description>&lt;p&gt;&lt;strong&gt;In an ideal world, every piece of code we write would be easily testable, clearly understood, and perfectly maintainable. However, reality often presents us with complex problems and solutions that aren&amp;rsquo;t always straightforward. Writing testable code sometimes requires a thoughtful approach, deep consideration of the use cases, and even refactoring to ensure that the code is robust and fully tested.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;h2 id="the-challenge-of-testing"&gt;The Challenge of Testing&lt;/h2&gt;&#10;&lt;p&gt;Imagine a scenario where you need to create an Amazon S3 client based on different credential providers. At first glance, the implementation might seem simple. However, when it comes to writing unit tests for this code, challenges arise.&lt;/p&gt;</description></item><item><title>Exploring File Storage Solutions in Spring Boot</title><link>https://foojay.io/today/exploring-file-storage-solutions-in-spring-boot-database-local-systems-cloud-services-and-beyond/</link><pubDate>Wed, 23 Aug 2023 08:07:19 +0000</pubDate><guid>https://foojay.io/today/exploring-file-storage-solutions-in-spring-boot-database-local-systems-cloud-services-and-beyond/</guid><description>&lt;p&gt;&lt;strong&gt;When building a web application, managing file uploads properly is a common requirement. After receiving, files can be stored in several places: in a file system, in a database or, more commonly, in a cloud storage service.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;&lt;strong&gt;In this article, we will cover how to store files in a database using Spring Boot and discuss some alternatives.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;h2 id="introduction"&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/h2&gt;&#10;&lt;p&gt;Recently, a fellow developer who I helped in past reached out to me on Slack seeking assistance with handling file uploads in a Spring Boot application. After providing some guidance, I decided to compile this article to assist others facing similar challenges.&lt;/p&gt;</description></item><item><title>Thread-Safe Counter in Java: A Comprehensive Guide</title><link>https://foojay.io/today/thread-safe-counter-in-java-a-comprehensive-guide/</link><pubDate>Thu, 17 Aug 2023 06:59:29 +0000</pubDate><guid>https://foojay.io/today/thread-safe-counter-in-java-a-comprehensive-guide/</guid><description>&lt;p&gt;&lt;strong&gt;In this tutorial, we will explore the concept of thread safety in Java, specifically focusing on a simple counter.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;We will start by understanding why a basic counter is not safe for multiple threads; then, we will progressively enhance its thread safety using different techniques such as synchronization, locks, Unsafe, VarHandle, and finally, AtomicInteger.&lt;/p&gt;&#10;&lt;p&gt;We will be referencing the code from this &lt;a href="https://github.com/rokon12/counter" target="_blank" rel="noopener noreferrer"&gt;repository&lt;/a&gt; throughout the tutorial.&lt;/p&gt;&#10;&lt;p&gt;Before we dive into the different implementations, let&amp;rsquo;s define a Counter interface that all our counter classes will implement.&lt;/p&gt;</description></item><item><title>Sealed Interfaces &amp; Pattern Matching: Java's Modern Capabilities</title><link>https://foojay.io/today/sealed-interfaces-and-pattern-matching-a-quick-dive-into-javas-modern-capabilities/</link><pubDate>Wed, 09 Aug 2023 07:01:51 +0000</pubDate><guid>https://foojay.io/today/sealed-interfaces-and-pattern-matching-a-quick-dive-into-javas-modern-capabilities/</guid><description>&lt;p&gt;&lt;strong&gt;Sealed classes in Java are a new feature that provides a way to restrict the classes that can inherit from a superclass or extend an interface. This new language feature enhances the encapsulation and provides more control to developers over their codebase.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;In this tutorial, we will explore sealed classes, how to use them to find all subclasses, and how to apply pattern matching in a practical context.&lt;/p&gt;&#10;&lt;p&gt;Let&amp;rsquo;s start with a basic interface definition named &lt;code&gt;Shape&lt;/code&gt;.&lt;/p&gt;</description></item><item><title>Book Review: "OpenJDK Migration for Dummies"</title><link>https://foojay.io/today/book-review-openjdk-migration-for-dummies/</link><pubDate>Fri, 04 Aug 2023 09:02:46 +0000</pubDate><guid>https://foojay.io/today/book-review-openjdk-migration-for-dummies/</guid><description>&lt;p&gt;&lt;strong&gt;The subject of Java licensing and OpenJDK migration is complex and vital to many software engineers.&lt;/strong&gt; &lt;strong&gt;I am no different. It&amp;rsquo;s a topic often shrouded in legal jargon and technicalities, making it difficult to approach.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;&amp;ldquo;OpenJDK Migration for Dummies&amp;rdquo; by&lt;a href="https://www.linkedin.com/in/siritter/" target="_blank" rel="noopener noreferrer"&gt;Simon Ritter&lt;/a&gt; offers a fresh perspective, breaking down these challenges into digestible segments. (&lt;a href="https://www.azul.com/openjdk-migration-for-dummies/" target="_blank" rel="noopener noreferrer"&gt;Get it for free here.&lt;/a&gt;)&lt;/p&gt;&#10;&lt;p&gt;&lt;a href="https://www.azul.com/openjdk-migration-for-dummies/" target="_blank" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;/p&gt;&#10;&lt;p&gt;[&lt;/p&gt;&#10;&lt;figure class="alignright"&gt;&#10; &lt;img src="https://foojay.io/today/book-review-openjdk-migration-for-dummies/dummies-373x510.png" alt="" width="270" height="369" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;](&lt;a href="https://www.azul.com/openjdk-migration-for-dummies/" target="_blank" rel="noopener noreferrer"&gt;https://www.azul.com/openjdk-migration-for-dummies/&lt;/a&gt;)&lt;/p&gt;&#10;&lt;p&gt;The book directly speaks to my core expertise in Java, providing clarity and guidance.&lt;/p&gt;</description></item><item><title>Preparing for JDK 21: A Comprehensive Overview of Key Features and Enhancements</title><link>https://foojay.io/today/preparing-for-jdk-21-a-comprehensive-overview-of-key-features-and-enhancements/</link><pubDate>Wed, 02 Aug 2023 10:46:28 +0000</pubDate><guid>https://foojay.io/today/preparing-for-jdk-21-a-comprehensive-overview-of-key-features-and-enhancements/</guid><description>&lt;p&gt;&lt;strong&gt;As we inch closer to the release of JDK 21 in September (next month!), it&amp;rsquo;s crucial to familiarize ourselves with the transformative features and improvements this version is poised to bring to the Java ecosystem.&lt;/strong&gt;&lt;/p&gt;&#10;&lt;p&gt;Let&amp;rsquo;s embark on a comprehensive tour of the noteworthy changes and enhancements in JDK 21.&lt;/p&gt;&#10;&lt;h2 id="revising-the-balance-of-serviceability-and-performance-with-jep-451"&gt;Revising the Balance of Serviceability and Performance with JEP 451&lt;/h2&gt;&#10;&lt;p&gt;Let&amp;rsquo;s begin with JEP 451, &amp;ldquo;Prepare to Disallow the Dynamic Loading of Agents.&amp;rdquo; Graduating to Completed status in preparation for JDK 21, this proposal doesn&amp;rsquo;t ban the dynamic loading of agents into a running JVM outright. Instead, it issues warnings when such loading happens, preparing the terrain for a future JDK release that will disallow such loading by default.&lt;/p&gt;</description></item><item><title>Busting Myths, Building Futures: A Conversation with Cay Horstmann on Java and Machine Learning</title><link>https://foojay.io/today/busting-myths-building-futures-a-conversation-with-cay-horstmann-on-java-and-machine-learning/</link><pubDate>Mon, 24 Jul 2023 15:12:00 +0000</pubDate><guid>https://foojay.io/today/busting-myths-building-futures-a-conversation-with-cay-horstmann-on-java-and-machine-learning/</guid><description>&lt;figure class="alignright size-medium is-resized"&gt;&#10; &lt;img src="https://foojay.io/today/busting-myths-building-futures-a-conversation-with-cay-horstmann-on-java-and-machine-learning/cay-pfh-big-edited.jpg" alt="" width="503" height="356" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;In our ongoing series of interviews with the movers and shakers of the software world, we bring you a conversation with Cay Horstmann, a towering figure in the Java community and a respected academic and entrepreneur.&lt;/p&gt;&#10;&lt;p&gt;Known for his prolific contributions in the form of textbooks, online content, and courses, Cay has been instrumental in shaping the Java education landscape.&lt;/p&gt;&#10;&lt;p&gt;In this insightful conversation, he speaks about a range of topics, including the challenges and potential for Java in the realms of data science and machine learning, the current state of the software development industry, the impact of AI on developers, and his unique perspective on learning by practice with immediate feedback. He also shares some intriguing anecdotes from his journey in academia and the software industry.&lt;/p&gt;</description></item><item><title>Dive into the OpenJDK: Top 10 Reads on Foojay.io</title><link>https://foojay.io/today/dive-into-the-openjdk-top-10-reads-on-foojay-io/</link><pubDate>Wed, 19 Jul 2023 07:45:04 +0000</pubDate><guid>https://foojay.io/today/dive-into-the-openjdk-top-10-reads-on-foojay-io/</guid><description>&lt;p&gt;Foojay.io is a community platform dedicated to the needs of Java developers (and beyond, e.g., Kotlin) who use OpenJDK and related technologies.&lt;/p&gt;&#10;&lt;p&gt;It serves as a central hub for sharing knowledge, resources, and tools related to Java and OpenJDK.&lt;/p&gt;&#10;&lt;p&gt;The platform offers a wide range of content, including articles, tutorials, and insights from industry experts and Java enthusiasts.&lt;/p&gt;&#10;&lt;p&gt;Whether you&amp;rsquo;re a seasoned developer or a beginner in the world of Java, Foojay.io provides valuable information and a supportive community to help you navigate and excel in your Java development journey.&lt;/p&gt;</description></item><item><title>Charting the Course of Java: An Insightful Conversation with Java Champion, Sebastian Daschner</title><link>https://foojay.io/today/charting-the-course-of-java-an-insightful-conversation-with-java-champion-sebastian-daschner/</link><pubDate>Tue, 11 Jul 2023 15:34:09 +0000</pubDate><guid>https://foojay.io/today/charting-the-course-of-java-an-insightful-conversation-with-java-champion-sebastian-daschner/</guid><description>&lt;figure class="alignright size-full is-resized"&gt;&#10; &lt;img src="https://foojay.io/today/charting-the-course-of-java-an-insightful-conversation-with-java-champion-sebastian-daschner/Sebastian.jpeg" alt="" width="375" height="375" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;In this insightful interview, renowned Java Champion, Oracle Developer Champion, and JavaOne Rockstar, Sebastian Daschner, shares his journey in the field of Java enterprise software development.&lt;/p&gt;&#10;&lt;p&gt;With a vast array of experience from being a self-employed consultant, trainer, and author to his contributions to the open-source community, Daschner provides a unique perspective on Java&amp;rsquo;s current state and future, especially in the enterprise context.&lt;/p&gt;&#10;&lt;p&gt;He delves into his strategies for balancing his varied roles, offers tips for aspiring developers, discusses the challenges in the software development industry, and underlines the importance of continuous learning.&lt;/p&gt;</description></item><item><title>The Evolution of Java: Challenging Stereotypes and Embracing Modernity</title><link>https://foojay.io/today/the-evolution-of-java-challenging-stereotypes-and-embracing-modernity/</link><pubDate>Fri, 07 Jul 2023 16:15:56 +0000</pubDate><guid>https://foojay.io/today/the-evolution-of-java-challenging-stereotypes-and-embracing-modernity/</guid><description>&lt;p&gt;On a flight from Zurich to Toronto, I found myself in an engaging conversation with a fellow passenger. Among various topics, our conversation navigated toward our careers and, inevitably, as I am a Java developer, towards the world of Java.&lt;/p&gt;&#10;&lt;p&gt;This gentleman, having worked with Java some 15-20 years ago, was surprised to learn that I still actively use the language. &amp;ldquo;Isn&amp;rsquo;t it slow?&amp;rdquo; he questioned. His question echoed a stereotype that I have often encountered, one that has stuck to Java from its earlier days.&lt;/p&gt;</description></item><item><title>Exploring the Depths of Java: A Comprehensive Conversation with Jakob Jenkov, Part-II</title><link>https://foojay.io/today/exploring-the-depths-of-java-a-comprehensive-conversation-with-jakob-jenkov-part-ii/</link><pubDate>Wed, 05 Jul 2023 16:21:30 +0000</pubDate><guid>https://foojay.io/today/exploring-the-depths-of-java-a-comprehensive-conversation-with-jakob-jenkov-part-ii/</guid><description>&lt;figure class="alignright size-full is-resized"&gt;&#10; &lt;img src="https://foojay.io/today/exploring-the-depths-of-java-a-comprehensive-conversation-with-jakob-jenkov-part-ii/jekov.jpeg" alt="" width="400" height="400" loading="lazy" class="is-zoomable"&gt;&lt;/figure&gt;&#10;&#10;&lt;p&gt;Welcome back to the second installment of our in-depth conversation with Jakob Jenkov, a leading figure in the world of Java. If you joined us for&lt;a href="https://foojay.io/today/exploring-the-depths-of-java-a-comprehensive-conversation-with-jakob-jenkov-part-i/"&gt;Part I&lt;/a&gt;, you&amp;rsquo;ll recall the insightful discussions around the evolving landscape of Java and its continuous improvements. Today, we delve even deeper into the subject. Jakob will share his thoughts on the challenges of modern software development, the impacts of artificial intelligence on developers, and much more. Get ready for another fascinating exploration into the depths of Java with Jakob Jenkov!&lt;/p&gt;</description></item></channel></rss>