top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

Difference Between Blocking code vs Non Blocking Code ?

0 votes
269 views
Difference Between Blocking code vs Non Blocking Code ?
posted Jul 9, 2014 by anonymous

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+1 vote

Which data structure they will be using and how it generates short url even for each site link with uniqueness ?

+1 vote

With the non-blocking asynchronous mongo java/scala driver, it is possible to define a wait time and a wait queue size for operations that cannot be executed directly with a free connection. When settings these values, the mongo driver will make the threads waiting for an available connection.

This behavior is very dangerous for an application written with non-blocking asynchronous IO in mind. These applications use a very limited number of threads (= numbers of cores). Blocking one of these thread can block the whole application.

What would be the recommended way to for this kind of applications? Should we set all these waiting settings to 0 and handle MongoWaitQueueFullException with retries in the application? Should the driver call an application callback when a connection is free?

0 votes

Am new to node.js.In every document i saw node js is nothing but non blocking and event driven.But am still unaware about what is non-blocking & event driven.Can any one please explain about this.

...