public ZooKeeperRegistrationSpec build() {
        final String serviceId = this.serviceId != null ? this.serviceId : UUID.randomUUID().toString();
        final ServiceInstance<?> serviceInstance =
                new ServiceInstance<>(serviceName, serviceId, serviceAddress, port, sslPort,
                                      payload, System.currentTimeMillis(), serviceType, uriSpec);
        return new CuratorRegistrationSpec(serviceInstance);
    }
Returns a newly-created {@link ZooKeeperRegistrationSpec} based on the properties set so far.
zookeeper3/src/main/java/com/linecorp/armeria/server/zookeeper/CuratorRegistrationSpecBuilder.java