First, the structure
The MySQL architecture is as follows:
Second, the lock
MySQL's locks are mainly divided into read and write locks. Read locks are shared, and at the same time multiple clients can perform read operations on the same resource. Write locks are exclusive and prevent other write-and read-lock operations.
Iii. Business
A transaction refers to an independent unit of work. This unit of work is either fully executed or not executed at all. If a statement does not execute correctly halfway through, the action that has been performed is rolled back.
The transaction has acid four properties, namely:
Atomicity (atomicity): A transaction is the smallest unit that is indivisible.
Consistency (consistency): The execution of a transaction causes the database to transition from one State directly to another state.
Isolation (insolation): When a transaction is not completed, the changes are not visible to other transactions.
Persistence (Durability): The execution of a transaction is persisted.
Four, deadlock
A deadlock is a situation in which two transactions lock two data and constantly try to acquire the other's lock. After a deadlock occurs, only partially or completely rolls back one of the transactions to break the deadlock.
V. Status monitoring
View the state of the user table by the Show table status like ' user ' statement.
Some basic concepts of MySQL