docstr: Called whenever a new deployment is created.
docstr_tok: ["Called","whenever","a","new","deployment","is","created","."]
code: def on_deployment_created(
      self,
      deployment_id: DeploymentID,
      scheduling_policy: SpreadDeploymentSchedulingPolicy,
  ) -> None:
      """Called whenever a new deployment is created."""
      assert deployment_id not in self._pending_replicas
      assert deployment_id not in self._launching_replicas
      assert deployment_id not in self._recovering_replicas
      assert deployment_id not in self._running_replicas
      self._deployments[deployment_id] = scheduling_policy
  
imports: import copy
  import sys
  from abc import ABC, abstractmethod
  from collections import defaultdict
  from dataclasses import dataclass
  from typing import Callable, Dict, List, Optional, Set, Tuple
  import ray
  from ray.serve._private.cluster_node_info_cache import ClusterNodeInfoCache
  from ray.serve._private.common import DeploymentID
  from ray.serve._private.utils import get_head_node_id
  from ray.util.scheduling_strategies import PlacementGroupSchedulingStrategy
label_desc: Use image node_id 2 for calling the DefaultDeploymentScheduler obj's underlying member method code with example usage: obj.on_deployment_created(deployment_id, scheduling_policy) without return types