How do you understand the difference between blocking non-blocking and synchronous asynchrony?

Source: Internet
Author: User

Lao Zhang Love tea, nonsense do not say, boiled water.
Appearance characters: Lao Zhang, Kettle Two (ordinary kettle, referred to as a water bottle, the kettle will ring, referred to as the kettle).
1 Lao Zhang put the kettle on the fire and conforming the water. (Synchronous blocking)
Lao Zhang thinks he's a little silly.

2 Lao Zhang put the kettle on the fire, go to the living room to watch TV, and occasionally go to the kitchen to see if the water is open. (Synchronous non-blocking)

Lao Zhang still feel a little silly, then become high-end, bought a will ring flute of that kind of kettle. After the water is open, you can make a loud noise.

3 Old Zhang put the kettle on the fire and conforming the water. (Asynchronous blocking)
Lao Zhang thinks such a silly meaning is not very important

4 Old Zhang put the kettle on the fire, went to the living room to watch TV, the kettle rang no longer to see it, rang again to get the pot. (Asynchronous non-blocking)
Lao Zhang thought he was smart.

The so-called synchronous asynchronous, just for the kettle. Ordinary kettle, synchronous; kettle, asynchronous.
Although all can work, but the kettle can be completed after their own, the old Zhang Water opened. This is not an ordinary kettle. Synchronization can only allow callers to poll themselves (in case 2), resulting in inefficient old Zhang.
The so-called blocking non-blocking, only for the old Zhang. The old Zhang of conforming, blocking; Old Zhang watching TV, non-blocking. Situation 1 and situation 3 old Zhang is blocked, the daughter-in-law shouted he did not know. Although the 3-ring kettle is asynchronous, it does not make much sense to conforming's old Zhang. So asynchronous is generally used in conjunction with non-blocking, in order to play an asynchronous effect.
--source network, author unknown

How do you understand the difference between blocking non-blocking and synchronous asynchrony?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.