In this blog post “Balanced Binary Search Tree“, I introduce two balanced binary search trees, which are AVLTree and RedBlackTree. AVLTree is efficient for search. Its time complexity is O(logN) for search, insertion and deletion. It usually takes one top-down… Read More
an introduction to young generation collection
In the post ‘brief introduction to java generation memory‘, I explained the functionality of the young generation and old generation. These two generation spaces consist of the main heap of the java application. In fact, there is a third generation… Read More
balanced binary search tree
Recently I am reading books about trees, which are data structures that can be used to stored data elements. Among various types of trees, balanced binary search tree (I will use BBST for short in this post) is a notable… Read More
brief introduction to java generation memory
Java VM uses a generational garbage collector, which relies on the below two observations: Most allocated objects will become unreachable quickly There are few references from older object to younger objects According to the above hypothesis, Java VM divides the… Read More
a few words about RSA
Symmetric Key Cryptography is used to transfer a message securely between two endpoints using a shared secret key. The message is encrypted using a shared secret key in one endpoint and transferred to the other endpoint. Then the message is… Read More
Diffie Hellman Key Exchange Algorithm
In an interview, one may be asked how an security connection is established between two endpoints using TLS protocol. He may answer the below steps: 1. A client sends a ClientHello message to a server with the client capabilities 2.… Read More
recommend a website for tls handshake analysis
These days I read a few articles about Transport Layer Security (TLS) protocol. I found two articles that are good enough to dive into the TLS handshake. For TLS 1.2 https://tls.ulfheim.net/ For TLS 1.3 https://tls13.ulfheim.net/ These two articles analyze… Read More
an introduction to parallel garbage collection
These days I am reading a book about Java Performance. One of its chapter is about Parallel Garbage Collection, which I think is really short and key-points focused. In this post, I will summarize some points that I consider useful.… Read More
data consistence between cache and database — cache aside
One question that may be frequently asked during an interview is that how you ensure data consistence between cache and database in an application. In this post, I will introduce some possible solutions and their drawbacks. While some of them… Read More
an introduction to channels in golang
Channels are commonly used to communicate messages among goroutines in golang. In this post, I will briefly introduce the channels in golang. Goroutines are light-weight threads in golang. When a goroutine wants to communicate with another goroutine, it can use… Read More