All Posts

Insecure Jenkins Credentials

Recently, while using Jenkins, I suddenly realized that I have always used Credentials to store encrypted information. But is it really safe? This led to the creation of this article to briefly explain that it is not completely secure.

Create Operator With Operator SDK

In these articles, I introduced the concept of Operator and the ways to implement it. Now, almost 5 years have passed since those articles were written. Although the Operator SDK hasn't changed much, it has seen some enhancements. Therefore, in this article, I will further introduce a new tool: OLM.

A Memo About The Live Incident For Kafka Migration

In this article, I will review an incident related to migrating Kafka that I encountered during my work. Although the issue fundamentally stemmed from a lack of rigor in the operation process, there are still some valuable lessons to be learned from this migration. Therefore, while I still remember some of the details, I want to take this opportunity to document the sequence of events and the reasons behind the problem.

Https Handshake Analysis Practice

Previously, I wrote an article introducing how HTTPS handshake works: HTTPS Handshake Process. However, that article was purely theoretical, describing how the HTTPS handshake process works in theory. Although it was quite helpful to me, when I actually analyzed HTTPS packets, I found that there was still a slight gap between theory and reality. So today, I will introduce it from a practical perspective, starting with real packets to see the entire process of HTTPS handshake.

Kafka Go SDK Usage and Keypoints

In this article, I will use the Go language as an example to demonstrate how to produce and consume messages through Kafka using the Sarama SDK. For message consumption, I will demonstrate two modes: auto-committing messages that have been consumed and actively committing message consumption ACKs. In fact, this is also the practice of different message processing models (i.e., at most once and at least once). However, I will not demonstrate the mode of consuming messages exactly once here because this is not a feature supported by a simple message queue. It requires some additional business support, so I will only briefly discuss it without deep dive.

Install and Operate Kafka

I recently used Kafka in a project and wanted to learn more about it. This article will cover the installation of Kafka and some commonly used commands for operating it. These commands are essential for development and troubleshooting.

How Go Detect CPU Core in Container

While reviewing the implementation code of a library, I noticed its dependency on viewing the number of CPU cores being utilized by processes and then imposing certain restrictions based on that. Hence, I took a look at how Go implements viewing the number of CPU cores.

Cloudflare R2 Guidence

Recently, I've noticed that Cloudflare's features are becoming more robust. They have even started supporting object storage, and the free tier is quite appealing. Intrigued by this, I decided to give it a try. This article documents my experimentation process and provides an overview of some usage methods.

Thinking about Go Module

In this article, I provided a brief overview of the core problems that Go Module aims to address and how it tackles them. I also discussed potential challenges and their solutions. Finally, I will introduce several common compatibility strategies, which are learned from the official documentation.

How Go implement ReadWrite Deadline In TCP

When writing Go networking applications, there is a series of TCP connection methods that I use a lot: `SetDeadline`, `SetReadDeadline`, `SetWriteDeadline`. Their purpose is to wait for a read or write operation on a TCP connection, and if there is no read or write operation at the preset time point, the read method will ErrDeadlineExceeded` error, which is often used to determine if a connection has been lost. In this article, I'll describe how to use them and how Go implements them, and try to achieve a similar effect in C++.