Sneak peek at the asynchronous Java

Java 19 is here with the preview of loom project. Loom project is the one helps Java become asynchronous and come back to the table to compete with other asynchronous language such as Golang. But why do we need Java to be asynchronous? Blocking It is all because we don’t want to be blocked. And the best example must be how you do your driver license renewal at the DMV. I remember I work up at 5:30 in the morning and drove to the DMV where there was already a line of 50 people. But I have no choice but to join them. After several hours’ waiting, I can finally check in and get a number for my case. Then I was eligible to walk in and find a chair to continue my waiting. After another couple hours, I finally got called at a window and finished my license renewal task. ...

September 16, 2023 · 3 min · 623 words · Me

The elegant consensus algorithm - Multi-Paxos - in Java gRPC

Introduction Paxos is a distributed consensus algorithm developed by Lamport. It is proved optimal and many systems are built based on it like chubby and zookeeper. But this article is not going to discuss Lamport’s orginal paper but focus on the engineering implementations. My colleague highly recommended Ongaro’s lecture of Paxos and said it is the best source of learning Paxos. I cannot agree more after studying it. That being said, I will briefly talk about Paxos and Multi-Paxos and dive into the engineering implementations. ...

September 16, 2023 · 6 min · 1122 words · Me

Why I don't like WSL

If you are not using Java or Intellij Idea for your project, you could stop reading. Couple months ago, I am very excited with WSL2 and it works perfectly for me to work on some Java projects in Intellij Idea. Somehow everything is upside down and obviously after some updates of windows though I still stick with win10. Long story short! Intellij Idea is really slow with WSL regarding the version. The indexing takes forever and it is not new as I found in this thread and this thread and the problem could be one of the following: ...

September 16, 2023 · 2 min · 281 words · Me