@Deprecated
    public VirtualHostBuilder hostnamePattern(String hostnamePattern) {
        if (defaultVirtualHost) {
            throw new UnsupportedOperationException(
                    "Cannot set hostnamePattern for the default virtual host builder");
        }

        checkArgument(!hostnamePattern.isEmpty(), "hostnamePattern is empty.");

        final HostAndPort hostAndPort = HostAndPort.fromString(hostnamePattern);
        if (hostAndPort.hasPort()) {
            port = hostAndPort.getPort();
            checkArgument(port >= 1 && port <= 65535, "port: %s (expected: 1-65535)", port);
            hostnamePattern = hostAndPort.getHost();
        }

        validateHostnamePattern(hostnamePattern);

        this.hostnamePattern = normalizeHostnamePattern(hostnamePattern);
        return this;
    }
Sets the hostname pattern of this {@link VirtualHost}.
If the hostname pattern contains a port number such {@code *.example.com:8080}, the returned virtual host
will be bound to the {@code 8080} port. Otherwise, the virtual host will allow all active ports.

@throws UnsupportedOperationException if this is the default {@link VirtualHostBuilder}

@deprecated prefer specifying the hostnamePattern using {@link ServerBuilder#virtualHost(String)}
            or {@link ServerBuilder#withVirtualHost(String, Consumer)}
core/src/main/java/com/linecorp/armeria/server/VirtualHostBuilder.java