worker: Use nsock_write_all in master-worker communication

When the data is very long - or when a signal happens - writes would
fail, leading to events that should trigger on workers but didn't, or
responses that went missing.

Using nsock_write_all to ensure the rest of the query/response is
written when the interruption is over - we don't end up with messages
about core workers "seems to be chocked", when they're in fact not at
all, or that the resulting "Job with id '288' doesn't exist", which is
true, but only because we fucked up creating said job.

Change-Id: I39c648ebfb185c541435d64f95881e65705c0be6
Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>