Today's Question:  What does your personal desk look like?        GIVE A SHOUT

SEARCH KEYWORD -- Asynchronous



  The basics of Client/Server socket programming

  While Client/Server communication model is ubiquitous nowadays, most of them involve socket programming knowledge. In this post, I will introduce some rudimentary aspects of it: (1) Short/Long-lived TCP connection.Short-lived TCP connection refers to following pattern: Client creates a connection to server; send message, then close the connection. If Client wants to transmit information again, repeat the above steps. Because establishing and destroying TCP s...

       2017-09-26 19:43:10

  Different ways of handling concurrent job in GoLang

GoLang provides very good support of concurrency and the way to make some code to run concurrent is pretty simple and straightforward. Adding a simple go before a normal function call will make the function call asynchronous. In real cases normally people would concurrently run some jobs to improve the speed and efficiency. One important part of running jobs concurrently is about aggregating results so that the consequent function call would be able to proceed. There are multiple ways handling t...

   COMPARISON,WORKER POOL,WAITGROUP,CONCURRENT     2021-05-15 11:13:53

  7 Resources Every JavaScript Developer Should Know

A web developer today is expected to be an expert in every aspect of their craft and JavaScript is no exception.  Years ago JavaScript seemed to be more of an annoyance, producing those trailers at the bottom of the browser.  This has changed and JavaScript is a first-class citizen as a functional programming language and what seems like an unlimited number of resources covering the language. I have been doing more and more JavaScript lately, both on the front-end and some node.js...

   JavaScript,Resource,Study,Website     2012-03-15 12:54:40

  Latest : Asp.Net 5 Beta 7 Is Now Available

Asp.net developers can now use the latest update asp.net 5 Beta 7 on both NuGet and Visual Studio 2015 to make good asp.net development practices. The update also has the first public preview of .Net Execution Environment for Linux and Mac without any need of Mono. To know how to use asp.net 5 beta 7, read this article further. You need to install the update first to use its features with Visual Studio 2015. You can download and install it from Microsoft’s official site. The update brings ...

   ASP.NET 5 BETA 7     2015-09-18 06:33:54

  A Solution to CPU-intensive Tasks in IO Loops

Back in October 2011, Ted Dziuba infamously said that Node.js is Cancer.  A provocative title to a provocative article.  The only thing it didn’t really provoke in the commentary was much thought ;)  Zing. My interpretation of the article is that Ted holds up the classic blocking-IO process-per-request (or  thread per request; same difference) model as superior.  Yet we all remember where the blocking-IO forking model got Apache in the early days.  ...

   CPU,Intensive IO loops,Solution,C++     2012-02-06 07:42:40

  What drives the popularity of Node.js?

JavaScript is a programming language which can be used on both front end and back end. Its popularity should mainly be attributed to its power in front end side. While people seem not realize its power in back end until the appearance of Node.js.  Node.js is a server-side software system designed for writing scalable Internet applications, notably web servers. Programs are written on the server side in JavaScript, using event-driven, asynchronous...

   Node.ks,Popularity,NPM     2013-07-24 01:22:58

  How to handle ES6 modules in NodeJS

In modern JavaScript, there are two types of modules: ES6 module and CommonJS module used by NodeJS. These two types of module are not compatible. Many people would wonder how to load ES6 modules in their NodeJS project. This post will show how this can be done. Difference The syntax of the module being loaded is different. CommonJS modules are loaded with require() and exported with module.exports. ES6 modules are loaded and exported using import and export respectively. Merchanismwise require(...

   NODEJS,COMMONJS,ES6     2020-08-28 22:01:33

  gethostbyname vs getaddrinfo

getaddrinfo is slower than ping when resolving domain names. I think ping uses gethostbyname to resolve a domain name. The question becomes whether getaddrinfo is slower than gethostbyname. After testing with both functions, we find that getaddrinfo is really slow compared to gethostbyname. By strace tracking,  we find getaddrinfo will communicate with DNS server 10 times and gethostbyname will communicate with DNS server communication twice.gethostbyname is an old way to resolve domain nam...

   C++,network,DNS     2012-08-15 14:06:34

  What should video website do besides buying copyright?

Several major video sites in China seem to be designed by the same team, they look the same from the main interface to advertising scheme. The question is whether video sites really do not need to improve their products and user experience in addition to smashing the money to buy the copyright to attract users, is there no other choice? After reading this article, perhaps we can somehow have different views.The Web 2.0 era's video siteIn Web 1.0 era, the main way for users to obtain information...

   Video site, Copyright,User experience     2013-03-06 03:15:39

  Native Client Brings Sandboxed Native Code to Chrome Web Store Apps

Wouldn’t it be great if you could create web apps using your existing C and C++ code? Native Client lets you do just that, and it is now enabled for Chrome Web Store apps in Google Chrome’s beta channel. Native Client apps live on the web platform, so you don’t need to create separate versions of your app for each operating system. Rather than relying on OS-specific APIs, Native Client apps use Pepper, a set of interfaces that provide C and C++ bindings to the capabilities o...

   C++,Web application,Native Client,Useful     2011-08-24 02:23:03