class_docstr: Multi-application config for deploying a list of Serve applications to the Ray
  cluster.
  
  This is the request JSON schema for the v2 REST API
  `PUT "/api/serve/applications/"`.
  
  NOTE: This config allows extra parameters to make it forward-compatible (ie
        older versions of Serve are able to accept configs from a newer versions,
        simply ignoring new parameters)
class_docstr_tok: ["Multi-application","config","for","deploying","a","list","of","Serve","applications","to","the","Ray","cluster",".","This","is","the","request","JSON","schema","for","the","v2","REST","API","`","PUT","``","\/api\/serve\/applications\/","''","`",".","NOTE",":","This","config","allows","extra","parameters","to","make","it","forward-compatible","(","ie","older","versions","of","Serve","are","able","to","accept","configs","from","a","newer","versions",",","simply","ignoring","new","parameters",")"]
code: def nested_host_and_port(cls, values):
      # TODO (zcin): ServeApplicationSchema still needs to have host and port
      # fields to support single-app mode, but in multi-app mode the host and port
      # fields at the top-level deploy config is used instead. Eventually, after
      # migration, we should remove these fields from ServeApplicationSchema.
      for app_config in values.get("applications"):
          if "host" in app_config.dict(exclude_unset=True):
              raise ValueError(
                  f'Host "{app_config.host}" is set in the config for application '
                  f"`{app_config.name}`. Please remove it and set host in the top "
                  "level deploy config only."
              )
          if "port" in app_config.dict(exclude_unset=True):
              raise ValueError(
                  f"Port {app_config.port} is set in the config for application "
                  f"`{app_config.name}`. Please remove it and set port in the top "
                  "level deploy config only."
              )
      return values
  
imports: import logging
  from collections import Counter
  from dataclasses import dataclass, field
  from enum import Enum
  from typing import Any, Dict, List, Optional, Set, Union
  from zlib import crc32
  from ray._private.pydantic_compat import BaseModel, Extra, Field, root_validator, validator
  from ray._private.runtime_env.packaging import parse_uri
  from ray.serve._private.common import ApplicationStatus, DeploymentStatus, DeploymentStatusTrigger, ProxyStatus, ReplicaState, ServeDeployMode
  from ray.serve._private.constants import DEFAULT_GRPC_PORT, DEFAULT_UVICORN_KEEP_ALIVE_TIMEOUT_S, SERVE_DEFAULT_APP_NAME
  from ray.serve._private.deployment_info import DeploymentInfo
  from ray.serve._private.utils import DEFAULT
  from ray.serve.config import ProxyLocation
  from ray.util.annotations import PublicAPI
label_desc: Use image node_id 4 for calling the ServeDeploySchema obj's underlying member method code with example usage: obj.nested_host_and_port(cls, values) and returns: values