} finally {
taskLock.readLock().unlock();
}
long reqId = requestCounter.incrementAndGet();
TezHeartbeatRequest request = new TezHeartbeatRequest(reqId, events,
containerIdStr, taskAttemptID, eventCounter, eventsRange);
if (LOG.isDebugEnabled()) {
LOG.debug("Sending heartbeat to AM"
+ ", request=" + request.toString());
}
TezHeartbeatResponse response = umbilical.heartbeat(request);
if (LOG.isDebugEnabled()) {
LOG.debug("Received heartbeat response from AM"
+ ", response=" + response);