Java Annotated Monthly – March 2023
March is upon us, and with the year in full swing, there are more and more updates, helpful tricks, and innovations to keep track of. To help in this endeavor, we’re bringing you a fresh batch of articles on Java that can help you optimize your code and find new ways to streamline your workflow. This edition also includes everything you need to know about the latest updates to Kotlin, showcasing its technological innovations.
Sit back and enjoy our latest picks from the development community.
Java News Roundup 1, 2, 3, 4 – Peruse this selection of news, updates, and trends from the world of Java.
Java 20 sneak peek – Mohamed Taman describes the targeted features for the release planned for March 21, 2023, including JEPs for scoped values, record patterns, pattern matching for switch statements and expressions, a foreign function and memory API, virtual threads, and structured concurrency.
JDK 21: Image Performance Improvements – Learn about a method that helped make Java’s image-handling library faster.
Java 21: Performance Improvements Revealed – Guided by Per Minborg, see how much faster your code has become due to recent internal performance optimizations made in the Java Core Libraries.
Quality Outreach Heads-up – JDK 20: Deprecate URL Public Constructors – JDK 20 will deprecate all public constructors of java.net.URL. Developers should treat this as a strong warning discouraging their use.
Jarviz Delivers Inspection and Insights to JAR Files – This article introduces a new Java JAR inspection and insights tool called Jarviz, which helps developers find different bytecode versions in a JAR and query it for attributes, services, and more.
From Java Security with Love – Inside Java Newscast #42 – This newscast provides an introduction to the recent enhancements on cryptography, PKI, TLS, and tools, plus a sneak preview of the progress JDK 20 is making on the security side.
Microsoft OpenJDK Introduces Experimental Feature for Improving Escape Analysis – This is a new experimental feature, still under development, which improves the performance of escape analysis by increasing the opportunities for scalar replacement. Currently, the feature is only available for the Microsoft Build of OpenJDK, but it might become part of OpenJDK in the future.
Java Tutorials and Tips
Foreign Function & Memory (FFM) API Live – During this short talk by Per Minborg, recorded during Jfokus 2023, you will learn what FFM offers and how to apply it in your code.
What Should I Know About Garbage Collection as a Java Developer? – In the article, several engineers explain how garbage collection is performed, what stages it includes, which types of garbage collectors exist, and more.
Java Records as Embeddables with Hibernate 6 – Find out why Hibernate doesn’t fully support records and how the EmbeddableInstantiator feature allows you to map a record as an embeddable.
Write Efficient Bug-free and Simple Comparators in Java – JEP Café #17 – Though comparators are fairly common elements that are easy to write, you should still follow several subtle rules. Listen to this installment of JEP Café to learn about these guidelines.
Future Java – Prepare Your Codebase Now! – Inside Java Newscast #41 – Find out what the security manager, applet API, finalization, and primitive wrapper constructors have in common. Learn more about CMS, Nashorn, RMI activation, and biased locking, and discover what the jdeprscan tool has to do with all of this.
Java Bytecode Simplified: Journey to the Wonderland (Part 3) – Read this article to learn more about the tools for editing and manipulating Java bytecode.
Java Flight Recorder as an Observability Tool – Ben Evans, a Senior Principal Software Engineer at Red Hat, explains recent developments with JFR and discusses how tooling based on it fits into the growing field known as Observability.
Java Modules in Real Life – Nikolai Parlog offers advice about how, why, and when to use Java modules in real life.
What good are Record Patterns in Java? An example based on Spark’s Catalyst Optimizer and its Tree Rewriting Rules – Check out the implementation of a full program that provides a multi-pass expression simplifier using Record Patterns.
I Don’t TDD: Pragmatic Testing With Java – In this video, Marco Behler lays out the challenges of pragmatic testing along with strategies for use in real-life applications, which can be particularly tricky to test.
The code quality pyramid – Fabian Zeindl presents the code quality pyramid, which can help you classify issues you’ve already identified and decide which problems to tackle first. He also provides practical tips that you can use as starting points for improvements.
5 Amazingly Comfortable Java Libraries – Check out this selection of Java libraries to make your coding experience easier.
IntelliJ Navigation Shortcuts You Need to Know – Sebastian Daschner shares his favorite IntelliJ IDEA navigation shortcuts, which will let you work mouse-free, increasing focus and reducing friction.
How To Scan a URL for Malicious Content and Threats in Java – This is a hands-on guide about avoiding the embarrassment of clicking on malicious links.
The Beauty of Java Optional and Either – This article provides comprehensive examples of chaining Optional and Either.
An Introduction to Scoped Values in Java – The article investigates why scoped values were proposed in the first place and explains how to use them.
Java Sealed Classes in Action: Building Robust and Secure Applications – A N M Bazlur Rahman explains Java Sealed Classes and gives comprehensive use cases.
Languages, Frameworks, Libraries, and Technologies
This Week in Spring 1, 2, 3 – Catch up on the latest news and updates related to Spring in this series of articles.
Introducing Microservices Patterns with Spring Integration – In this article, Artem Bilan shares his Microservices Patterns with Spring Integration project, which is a catalog of working samples for microservices patterns described in Microservice Architecture.
A Bootiful Podcast: opensource, Spring Cloud, and Kubernetes maestro Abel Salgado Romero – In this episode, Josh Long and Abel Salgado Romero discuss how to build Kubernetes controllers with Spring Boot and GraalVM native images.
Upgrade Guide To Spring Boot 3.0 for Spring Data JPA and Querydsl – Read this article if you plan to update JPA and Querydsl to Spring Boot 3.0.2. The author highlights what changes you should keep in mind in the process.
Hibernate 6 – what’s new and why it’s important – The release of Hibernate 6 is significant in many ways, as it supports modern JDK and Jakarta specifications, provides a better API for developers, and offers new internal architecture that can serve as a solid base for the faster development of future versions.
Consider All Microservices Vulnerable — And Monitor Their Behavior – If you’ve ever wondered how to protect microservices from exploitation, this article is for you. It presents different stages in the life of any service from a security standpoint and introduces Security-Guard, an open-source project offering security-behavior monitoring and control of Kubernetes microservices.
Apache Kafka Introduction, Installation, and Implementation Using .NET Core 6 – If you are just getting started with Apache Kafka, this article is a great resource, as it explains Apache Kafka basics, installation, and operation, in addition to offering step-by-step implementation instructions using a .NET Core 6 web application.
Article Series: Developing Apache Kafka applications on Kubernetes – The article presents a set of posts about how to provision, configure, and secure an Apache Kafka cluster on a Kubernetes cluster.
Legacy Code Refactoring: Tips, Steps, and Best Practices – Can outdated systems become modern and progressive? This guide on legacy code refactoring gives your old code a chance!
10 Most Popular Frameworks for Building RESTful APIs – Many API frameworks work for creating RESTful APIs. In his article, Derric Gilling, assembles a list of such frameworks along with their advantages and disadvantages. After reading it, you’ll better understand which is the right choice for you.
Carnegie Mellon Researchers Develop AI Model for Human Detection via WiFi – Can this innovation solve an age-old problem by enabling the creation of a decent bathroom occupancy sensor? Find out in this blog post.
SBOMs: First Steps in a New Journey for Developers – Have you heard of the acronym “SBOM”? If not, read this article to understand what it is, how it works, and, most critically, why it has become so important.
Along Came a Bug – There is so wide a variety of approaches to fixing bugs, that it can often feel overwhelming. Nevertheless, a new set of innovative practices has entered the scene. Will you try them out?
Increase Your Code Quality in Java by Exploring the Power of Javadoc – Learn what Javadoc is and how to avoid unnecessary noise in Java code documentation.
OpenAI Releases an Advanced Classifier to Distinguish AI and Human Writing Styles – Another cool story has emerged from the field of AI. A newly released, trained classifier can predict the likelihood that AI generated a given piece of text.
Own Your IDE – Donald Raab shares his favorite customization features in IntelliJ IDEA.
An Overview of Programming Languages – If you find yourself feeling lost among the numerous programming languages without a sense of which is the best choice for your needs, check out this list.
I Completed All 8 Advents of Code in One Go: Here Are the Lessons I Learned. – Teiva Harsanyi wrote 34,281 lines of code while completing 7 years of Advent of Code tasks. Check out what he has to say about his genuinely fantastic experience.
Build an AI Chatroom With ChatGPT and ZK by Asking It How! – Hawk Chen shows how he made a chatroom web application that allows you to input messages and converse with ChatGPT.
What Is ChatGPT Doing … and Why Does It Work? – Dive deep into what is going on inside ChatGPT.
Foojay Podcast #14: Debugging Tools and Skills for Fun and Profit – Listen to this podcast to learn more about the IntelliJ IDEA debugger, JDWP protocol, exception breakpoints, external debugging tools, and more.
How to Setup Spring Boot With Vue.js Frontend – In this blog post, you will learn how to set up a Maven multi-module project consisting of a Spring Boot backend and a Vue.js frontend.
How to Build an SBOM – Gunter Rotsaert shares his knowledge about SBOM and how to build it in an automated way.
The Importance of Writing Stuff Down – Why is it important to create issues with bugs? The real-life example in this article explains it.
Reproducible Kotlin Compiler Artifacts – It’s now possible to build Kotlin projects locally, but get the same set of artifacts that we publish to GitHub and Maven Central after each Kotlin release. Read this article to find out why this is important.
Kotlin News: 1.8.0 Is Here, Roadmap for 2023, KotlinDL on Android, and More! – This article lists the most recent Kotlin news and blogs.
Null Safety: Kotlin vs. Java – Nicolas Frankel expands on the problem of nullability and how it’s solved in Kotlin and Java.
The K2 Compiler is going stable in Kotlin 2.0 – This article explains what Kotlin 2.0 is and how the new frontend for the Kotlin compiler (code-named “K2”) will work with this version.
Update Regarding Kotlin/Native Targets – The team decided to split the targets into tiers and deprecate some of them. The latter are listed in this article.
Advanced Kotlin Techniques for Spring Developers – Watch this recorded webinar by Pasha Finkelshtein if you want to take your developer experience with Spring to the next level! You will learn to add new functionalities to existing classes with Kotlin extension functions, use Kotlin bean definition DSL, improve your application configurations with lateinit, and more.
Graceful Resource Handling Using Structured Concurrency in Kotlin – In this session, Simon Vergauwen shows how to use Arrow’s Resource Domain-Specific Language (DSL) to reason about resource safety. You will also see how this can be combined with KotlinX Coroutines to build complex use cases simply and elegantly using Kotlin DSLs.
Creative Coding With Kotlin and OPENRNDR – During this live coding session, you will follow the creation of a simple GUI with the help of the OPENRNDR library.
Kotlin database access with PostgreSQL and Exposed – Watch this video to learn how to use the JetBrains Exposed library to write to and read from PostgreSQL.
Simple Event Sourcing with Kotlin – Event Sourcing helps you store a list of the StockEvents – StockAdded, StockModified, and StockRemoved – instead of maintaining a database table of your stock. Duncan McGregor shows how to do this in this video.
Conferences and Events
The JUnconference Alliance – If you’ve heard of Java unconferences and wanted to know more about them, you may find this article helpful.
Culture and Community
Template for Efficient One-On-One Meetings – This post outlines the principles of a successful one-on-one and provides a Miro template you can use for meeting visualization and easier analysis after the fact.
Rocks, Pebbles, Sand: How to implement in practice – Find out how to apply the Rocks, Pebbles, Sand approach in the world of software development and create a simple sprint-planning system.
We Should Stop Trying to Make Scrum Fit for Every Situation – What sorts of teams need Scrum, and how do you recognize if yours isn’t one of them?
When Scrum Feels Like Dressing for Dinner – Here’s another blog post that analyzes the relevance of Scrum for modern software development.
Stanford Researchers Develop Brain-Computer Interface for Speech Synthesis – Incredible things are happening in the field of brain-computer interfaces (BCI)! Researchers from Stanford University have developed a new BCI for synthesizing speech from signals captured in a patient’s brain. The prototype system can decode speech at 62 words per minute, 3.4x faster than previous BCI methods.
IntelliJ IDEA Live Streams
OAuth for Java Developers – Matt Raible, web developer, Java Champion, and Developer Advocate at Okta, will give an overview of the current state of the OAuth ecosystem in Java. You’ll learn which frameworks support OAuth and which ones don’t.
Matt will also offer practical examples you can try for yourself in just a few minutes.
Here are the most exciting picks from our corporate blogs:
Pattern Matching in Java – 5 Examples for Busy Developers – Mala Gupta shares the 5 most common places in Java to use pattern matching. The blog post also links to a YouTube video if you’d rather watch than read.
Top 10 Plugins for IntelliJ-Based IDEs – This post offers a look at 2022’s most downloaded and highest-rated plugins on JetBrains Marketplace.
Debugger Upskill: Basic and Advanced Stepping – Start following our new series of blog posts about the powerful features of our built-in debugger. The first article introduces the concept of stepping and explains how to use stepping actions to their fullest potential.
Bootiful Spring Boot 3 – Watch this video in which Spring Developer Advocate Josh Long explores next-gen Spring.
Getting started with IntelliJ IDEA – If you’ve experienced blank-page anxiety after installing IntelliJ IDEA, this blog post is for you. Developer Advocate Helen Scott explains how to customize your IntelliJ IDEA environment and guides you through the process of writing, changing, testing, and navigating your first code, and more.
That’s all for today!
If you’d like to suggest content for the next issue of Java Annotated Monthly, please email us at (JAM@jetbrains.com) or get in touch on Twitter. If you lost track of an interesting article that you read in our JAMs, you can visit this page where all the previous editions are stored.
Subscribe to Blog updates
Thanks, we've got you!