Asynchronus Programming

 Asynchronus Programming


In conventional 'Synchronus Programming', all the routines run sequentially. For example, when there's a code like


a.run();

b.run();

c.run();


Synchronus code will run like a -> b -> c. However, in an asynchronous environment, like JS, the codes do not run sequentially. It runs concurrently.

This concept may not be understood intuitively for those who first meets the Asynchronous Programming. Let's think about a machines.


In contrast, asynchronous codes run like 'course of a Mario game'. All of the codes are running by itself, no matter of the input or output.

undefined

Let's think of a course for a Super Mario Bros. Your Mario will move freely, but the components of the course will run regardless of the play or location of your Mario; The canon will fire the bills regularly, and the turtles will wander around his position continuously.

Bill Blaster and Bullet Bill - New Super Mario U Guide - IGNKoopa Troopa | Neo Encyclopedia Wiki | Fandom


Non-Blocking



Message Queue

Message Queue is a broker that sends a 'message' between different services asynchronously.


Event-Driven Architecture

댓글

이 블로그의 인기 게시물

Interface of Java

Data Analytics Overview(OLTP vs OLAP)

Leetcode