Now, let's start considering several techniques that will come in handy when writing services.
Node runs as a single thread, so if every time it had to call a service, or read a file, or access a database, or do any other I/O-related operation, it would have to wait for it to finish, then attending requests would take a long time, blocking other requests from being attended, and the server would show a very bad performance. Instead, all operations such as those are always done asynchronically, and you must provide a callback that will be called whenever the operation is finished; meanwhile, Node will be available to process other clients' requests.
There are synchronous versions of many functions, but they can only be applied for desktop work, and never for web servers.
Node established a standard that all callbacks should...