I found the issue.
When I kill the worker and start a new worker, I do not add a listener for the newly created worked. Due to which the message is never received for the newly created worker.
Just by adding the following code, the issue was fixed.
cluster.on('exit', function(worker, code, signal) {
var w = cluster.fork();
console.log('worker %d died (%s). restarting...', worker.process.pid, signal || code);
w.on('message', function(msg){
workerStatus[w.id]=0;
console.log("Message Received : " + w.id);
});
});