When placing an order, using transaction line locks, the database can only process one transaction at a time?

  ios, question

I read these articles:

  1. http://www.blogjava.net/loocky/archive/2006/11/15/81138.html

  2. http://blog.csdn.net/xifeijian/article/details/20313977

  3. http://betakoli.iteye.com/blog/2257095

  4. http://www.cnblogs.com/chenwenbiao/archive/2012/06/06/2537508.html

These last few articles talked aboutmysql innodbSome of the transaction locks are used, and it feels like they all say that when placing an order, the inventory will be reduced by the specified line (FOR UPDATE) this kind of situation, that is to say, at the same time, there can only be one order transaction in execution, that is to say, this is serial?

This is just like going to the supermarket to check out one by one. The cashier can only check out one by one, while we can only wait in line with baskets.

This is the same time of the database. What is the concept of time, the same second, the same millisecond? Or is there no concept of time at all, just the concept of space, that is, only one transaction is executing at the same time and space, and the others are waiting in line?

Aren’t computers just for the liberation of mankind? What’s the difference between now and when the supermarket checks out, we have to wait in line? Isn’t that Low?

Does Taobao’s hundreds of millions of transactions per second also “submit” orders one by one? If so, how is it possible to have such a large volume of transactions in one second?

In addition, help me look at this problem:http://segmentfault.com/q/1010000004062810

Thank you very much!

Asynchronous can solve the problem you said.
Multiple toll gates are opened through distribution and clustering. You can solve your problem.