MySQL database implements master-master synchronization

Foreword MySQL master-master synchronization actually promotes slave database to master database on the basis of master-slave synchronization, so that they can read and write databases with each other, and slave database becomes master Database; the process of master-slave mutual authorization connection, reading the binlog log of the other party and updating it to the local […]

MySQL database realizes master-slave synchronization

Install MySQL database 8.0.32 Foreword Today, let’s learn the principle and process of database master-slave synchronization. The database is mainly used to store WEB data, which is extremely important in enterprises. Let’s take a look at it together. 1.1 The purpose of database master-slave MySQL master-slave replication is widely used in small and medium-sized enterprises […]

Spring transaction event control solves business asynchronous operation decoupling TransactionSynchronizationManager Transaction

Scene In business, it is often necessary to send messages or events to asynchronously call other components to perform corresponding business operations after performing database operations (transaction submission is completed). For example: After the user registers successfully, the activation code or activation email is sent. If the user saves and executes an asynchronous operation to […]

Semaphores for synchronization and mutual exclusion

Directory 1. The semaphore is used for mutual exclusion of threads verify 2. The semaphore is used for thread synchronization verify 3. The unnamed semaphore is used for inter-process mutual exclusion code one code two verify 4. The famous semaphore is used for inter-process synchronization and mutual exclusion verify Semaphore is widely used for synchronization […]

5.2 Synchronization of multiple threads

Thread sleep can be interrupted, through Threadinterrupt0), of course, one thread can call interrupt0) of another thread, and the thread sleep will enter the Runnable state after being interrupted. Since the definition of Thread.sleep( declares that an exception may be thrown in this method through the throw keyword, our program must use a try…catch code […]

elasticsearch and mysql data synchronization

Table of Contents data synchronization 1. Thought analysis 1. Synchronous call 2. Asynchronous notification 3. Monitor binlog 4. Choose 2. Realize data synchronization 1. Idea 2. Import the demo 3. Declare switches and queues 3.1 Introducing dependencies 3.2 Configuration file 3.3 Declare the queue switch name 3.4 Declaring a Queue Exchange 4. Send MQ message […]

DJ2-4 Process Synchronization (Lesson 1)

Directory 2.4.1 Basic Concepts of Process Synchronization 1. Two forms of constraints 2. Critical resource 3. Producer-Consumer Problem 4. Critical section 5. Rules to be followed by the synchronization mechanism 2.4.2 Hardware synchronization mechanism 1. Disable interrupt 2. Test-and-Set command 3. Swap command 4. Summary The asynchronous nature of the process will inevitably lead to […]

MySQL database + Docker master-slave synchronization build configuration

MySQL master-slave synchronization 1. Preface MySQL’s built-in replication capabilities are the foundation for building large, high-performance applications. Distribute MySQL data to multiple systems. This distribution mechanism is realized by copying the data of a certain mysql host to other hosts (slave) and re-executing it. During replication, one server acts as the master and one or […]

DJ2-4 Process Synchronization (Lesson 2)

Directory 2.4.3 Semaphore mechanism 1. Integer semaphore 2. Recorded semaphore 3. AND type semaphore 4. Semaphore set three special cases 2.4.4 Application of semaphore 1. Using semaphores to realize process mutual exclusion 2. Use semaphore to realize predecessor relationship 2.4.5 Monitor Mechanism 1. The composition of the tube process 2. Main features of the tube […]