code: public static Message buildHandshake(String nodeId) {
      Handshake handshake = Handshake.newBuilder().setNodeId(nodeId).build();
      return Message.newBuilder().setType(MessageType.HANDSHAKE)
                                 .setHandshake(handshake)
                                 .build();
    }
docs: Creates a HANDSHAKE message.
  
  @param nodeId the node ID in the handshake message.
  @return a protobuf message.