[concurrent programming] basic usage and implementation of Pool

Blogger introduction: - I am the official account of WeChat. The Milky way ]I look forward to your attention. Come on in the future~ preface Go is a programming language for automatic garbage collection. It uses three-color concurrent marking algorithm to mark objects and recycle them. Therefore, we generally use it whenever we want, wi ...

Posted by XaeroDegreaz on Thu, 20 Jan 2022 07:58:45 +0100

Why isn't the SimpleDateFormat class thread safe? (six solutions are attached, recommended Collection)

Hello, I'm glacier~~ First of all, ask everyone: is the SimpleDateFormat class you use safe? Why is the SimpleDateFormat class not thread safe? Take questions and seek answers from this article. When it comes to the SimpleDateFormat class, it must be familiar to children's shoes who have done java development. Yes, it is the date and time con ...

Posted by cac818 on Wed, 19 Jan 2022 19:30:59 +0100

[learning notes on multithreaded programming 8] thread synchronization using mutex

Statement: This study note is a summary based on the tutorial and combined with your own learning situation. It is not original. If you want to see the original version, please see the C language Chinese network Multithreaded programming (C language + Linux) , the website has many good programming learning tutorials, especially about C language ...

Posted by Atomic Taco on Wed, 19 Jan 2022 11:49:16 +0100

[high concurrency] deeply understand the execution sequence of threads

Hello, I'm glacier~~ Recently, readers often ask me: Glacier, in what order are threads executed? In order to answer everyone's question, I'll write a separate article today. Well, no more. Let's get to today's topic. 1, The execution order of threads is uncertain When calling the start() method of Thread to start the Thread, the execution orde ...

Posted by justphpdev on Tue, 18 Jan 2022 22:37:14 +0100

Multiplex IO transfer server

Multiplex IO transfer server The multi-channel IO transfer server is also called multi task IO server. The main idea of this kind of server is that the application program no longer monitors the client connection, but gives it to the kernel to replace the application program monitoring file. There are three main methods used: select, poll and ...

Posted by ROCKINDANO on Mon, 17 Jan 2022 08:43:18 +0100

Source code analysis of ConcurrentHashMap

Source code analysis of ConcurrentHashMap (1) Notice before reading All the contents of this article are the contents of the teacher's source code special training class. If you are interested, you can learn about a wave: https://space.bilibili.com/457326371?from=search&seid=882812707426049189This chapter requires some pre knowledge: Long ...

Posted by lucasmontan on Sat, 15 Jan 2022 08:47:57 +0100

Deeply understand the principle of ThreadLocal and the problem of memory leakage

ThreadLocal principle Before reading this article, you need to understand the concept of strong, weak and virtual in Java. The transmission address is: Detailed explanation of four references of strong, weak and virtual in Java 1, Introduction It can solve the data security problem of multithreading and associate the current thread with a ...

Posted by Louis-Platt on Fri, 14 Jan 2022 22:06:47 +0100

Kotlin collaboration 5 - using kotlin collaboration in Android

Kotlin collaboration series article navigation: Kotlin process I - Coroutine Kotlin collaboration process 2 - Channel Kotlin collaboration process III - data Flow Kotlin collaboration process IV -- Application of Flow and Channel Kotlin collaboration 5 - using kotlin collaboration in Android 1, Android MVVM architecture Architecture diagram of ...

Posted by blindSpot on Fri, 14 Jan 2022 20:49:00 +0100

ThreadLocal usage and full source code analysis

1. ThreadLocal introduction 1.1 official introduction From the description in the official Java document: the ThreadLocal class is used to provide local variables inside the thread. When this variable is accessed in a multithreaded environment (through get and set methods), it can ensure that the variables of each thread are relatively in ...

Posted by derksj on Fri, 14 Jan 2022 00:26:23 +0100

ThreadPool Knowledge Compilation for Java Concurrent Programming

The concurrent programming technology is a necessary knowledge in the development of Internet applications. The author of this article starts to analyze thread pools to gain a better understanding of concurrent programming in Java. * Above Thread Knowledge Compilation for Java Concurrent Programming The purpose and benefits of threads have bee ...

Posted by bengan on Mon, 10 Jan 2022 19:05:01 +0100