presto-spi/src/main/java/io/prestosql/spi/QueryId.java/QueryId/validateId
class QueryId:    public static String validateId(String id)
    {
        requireNonNull(id, "id is null");
        checkArgument(!id.isEmpty(), "id is empty");
        checkArgument(ID_PATTERN.matcher(id).matches(), "Invalid id %s", id);
        return id;
    }