Spring Boot 3.0 Is Out — But I'm Holding Off on Upgrading for Now
Spring Boot 3.0.0 was officially released on November 25, 2022. As someone who likes chasing the new and eating crab first, I had to upgrade and try it. In the end, though, I gave up.
108 posts
Spring Boot 3.0.0 was officially released on November 25, 2022. As someone who likes chasing the new and eating crab first, I had to upgrade and try it. In the end, though, I gave up.

Hey there. Do you want to take part in building the JH GitLab open source project and become a contributor, but as a newcomer you have no idea where to start? The truth is, anyone can join the JH GitLab open source project and become a contributor — technical background not required.

Before discussing volatile we need to understand JMM (Java Memory Model) first. Jumping straight to volatile without JMM feels odd, so let's cover JMM. To guarantee correctness of shared memory (visibility, ordering, atomicity), the memory model defines the rules for read/write behavior in multithreaded programs on shared memory systems.

The classic variable operation is increment: turning 1 into 2. Single-threaded, no problem. But the moment two threads operate on the same variable, trouble appears — that's related to Java's memory model, JMM, which I'll cover in the next article on volatile. If thread A already changed the variable to 2 while thread B increments at the same time without seeing that change and also sets it to 2, two increments should give 3 but give 2 instead. That's what brings CAS in.

Surely you've heard plenty of experts talk about AQS. So what is it? From the name AbstractQueuedSynchronizer we can guess it's an abstract queued synchronizer. Every character makes sense on its own; string them together and it stops making sense. Let's break it apart.

The entire organization can be commanded up and down through the mysterious API department. It speaks multiple official languages: REST API and GraphQL API. We'll start with REST. Before we begin, we need to apply for a token on JH GitLab — only a valid token lets you issue commands to this mysterious API department.

You're so eager to learn, fine, I'll tell you: our JH GitLab association can audit vulnerabilities for you too. In the Security Hall there are security masters who can scan the manual you wrote, covering Static Application Security Testing (SAST), Infrastructure as Code (IaC) scanning, Dynamic Application Security Testing (DAST), dependency scanning, container scanning, and more.

Xiaobai was strolling around JH GitLab when he ran into the Chief again and hurriedly stopped him: you said you'd teach me Docker cache optimization last time, tell me now. Chief: fine, you're eager to learn. Do you know our JH GitLab association has a Package Warehouse for managing artifacts? Xiaobai: of course, I've just never used it. How does it work?

Xiaobai has been wandering the jianghu for years. He heard that the leader of the Tianxia Hui is unmatched in martial arts, his Three-Part Return-to-Origin Qi (DevOps, DevSecOps, GitOps) invincible under heaven. One day he saw that JH GitLab Tianxia Hui was sending out hero invitations, recruiting Jihu heroes to join the internal testing hall and start training.

To understand why Optional exists, you first need to understand NPE. Many object-oriented languages have a null value: a pointer on the stack that points at a heap address that doesn't exist. Use that object and you get a NullPointerException. If you fail to anticipate the null case, your program crashes.
