Send an UPDATE message to the specified link carrying the specified 'node' * slots configuration. The node name, slots bitmap, and configEpoch info * are included. */
| 2819 | * slots configuration. The node name, slots bitmap, and configEpoch info |
| 2820 | * are included. */ |
| 2821 | void clusterSendUpdate(clusterLink *link, clusterNode *node) { |
| 2822 | clusterMsg buf[1]; |
| 2823 | clusterMsg *hdr = (clusterMsg*) buf; |
| 2824 | |
| 2825 | if (link == NULL) return; |
| 2826 | clusterBuildMessageHdr(hdr,CLUSTERMSG_TYPE_UPDATE); |
| 2827 | memcpy(hdr->data.update.nodecfg.nodename,node->name,CLUSTER_NAMELEN); |
| 2828 | hdr->data.update.nodecfg.configEpoch = htonu64(node->configEpoch); |
| 2829 | memcpy(hdr->data.update.nodecfg.slots,node->slots,sizeof(node->slots)); |
| 2830 | clusterSendMessage(link,(unsigned char*)buf,ntohl(hdr->totlen)); |
| 2831 | } |
| 2832 | |
| 2833 | /* Send a MODULE message. |
| 2834 | * |
no test coverage detected