fix #443 reconnection when the connection is dropped

Squashed commit of the following:

commit b129addce8bfee25ef1c1c28d88b030bd5f5b0d3
Author: David Yan <david@datatorrent.com>
Date:   Fri Dec 13 10:12:50 2013 -0800

    making numRetries settable

commit d9fb7c7009b59964be75ff4962036adedd55264e
Author: David Yan <david@datatorrent.com>
Date:   Fri Dec 13 09:50:37 2013 -0800

    trivial log message change

commit 63137559b84bb948ce613784e621677cac872524
Merge: 94b2308 119ad9e
Author: David Yan <david@datatorrent.com>
Date:   Fri Dec 13 09:33:37 2013 -0800

    Merge branch 'master' of https://github.com/DataTorrent/Malhar

commit 94b2308f83424431cd36c121311d7202e82a257d
Author: David Yan <david@datatorrent.com>
Date:   Thu Dec 12 13:05:40 2013 -0800

    fix #443 trying different way of handling reconnection

commit 25843bb469060ce999c14b2c0c9c6cfc78fad6dc
Author: David Yan <david@datatorrent.com>
Date:   Wed Dec 11 19:12:07 2013 -0800

    fix #443 added support of reconnect upon failure of sending message