Addition of send_slave_heartbeat option

Addition of send_slave_heartbeat option
This commit is contained in:
MassimilianoPinto
2015-09-30 14:39:26 +02:00
parent 4aa161d78e
commit f9ee9ca028
4 changed files with 35 additions and 11 deletions

View File

@ -1613,6 +1613,10 @@ int action;
slave->lastEventTimestamp = hdr->timestamp;
slave->lastEventReceived = hdr->event_type;
/* set lastReply */
if (router->send_slave_heartbeat == 1)
slave->lastReply = time(0);
pkt = gwbuf_alloc(hdr->event_size + 5);
buf = GWBUF_DATA(pkt);
encode_value(buf, hdr->event_size + 1, 24);