class_docstr: Manages a list of grpc connections.
  
  :param logger: the logger to use
  :param compression: The compression algorithm to be used by this GRPCConnectionPool when sending data to GRPC
docstr: Send a request to target via only one of the pooled connections
  
  :param request: request to send
  :param deployment: name of the Jina deployment to send the request to
  :param metadata: metadata to send with the request
  :param head: If True it is send to the head, otherwise to the worker pods
  :param endpoint: endpoint to target with the requests
  :param timeout: timeout for sending the requests
  :param retries: number of retries per gRPC call. If <0 it defaults to max(3, num_replicas)
  :return: asyncio.Task representing the send call
docstr_tok: ["Send","a","request","to","target","via","only","one","of","the","pooled","connections",":","param","request",":","request","to","send",":","param","deployment",":","name","of","the","Jina","deployment","to","send","the","request","to",":","param","metadata",":","metadata","to","send","with","the","request",":","param","head",":","If","True","it","is","send","to","the","head",",","otherwise","to","the","worker","pods",":","param","endpoint",":","endpoint","to","target","with","the","requests",":","param","timeout",":","timeout","for","sending","the","requests",":","param","retries",":","number","of","retries","per","gRPC","call",".","If","<","0","it","defaults","to","max","(","3",",","num_replicas",")",":","return",":","asyncio.Task","representing","the","send","call"]
code: def send_single_document_request(
      self,
      request: SingleDocumentRequest,
      deployment: str,
      metadata: Optional[Dict[str, str]] = None,
      head: bool = False,
      endpoint: Optional[str] = None,
      timeout: Optional[float] = None,
      retries: Optional[int] = -1,
  ) -> Optional[AsyncGenerator]:
      """Send a request to target via only one of the pooled connections
  
      :param request: request to send
      :param deployment: name of the Jina deployment to send the request to
      :param metadata: metadata to send with the request
      :param head: If True it is send to the head, otherwise to the worker pods
      :param endpoint: endpoint to target with the requests
      :param timeout: timeout for sending the requests
      :param retries: number of retries per gRPC call. If <0 it defaults to max(3, num_replicas)
      :return: asyncio.Task representing the send call
      """
      replicas = self._connections.get_replicas(deployment, head)
      if replicas:
          result_async_generator = self._send_single_doc_request(
              request,
              replicas,
              endpoint=endpoint,
              metadata=metadata,
              timeout=timeout,
              retries=retries,
          )
          return result_async_generator
      else:
          self._logger.debug(
              f"no available connections for deployment {deployment}"
          )
          return None
  
imports: import asyncio
  from typing import TYPE_CHECKING, Dict, List, Optional, Sequence, Set, Tuple, Union, AsyncGenerator
  import grpc
  from grpc.aio import AioRpcError
  from jina.constants import __default_endpoint__
  from jina.enums import PollingType
  from jina.excepts import InternalNetworkError
  from jina.importer import ImportExtensions
  from jina.logging.logger import JinaLogger
  from jina.proto import jina_pb2
  from jina.serve.helper import format_grpc_error
  from jina.serve.networking.connection_pool_map import _ConnectionPoolMap
  from jina.serve.networking.connection_stub import create_async_channel_stub
  from jina.serve.networking.instrumentation import _NetworkingHistograms, _NetworkingMetrics
  from jina.serve.networking.replica_list import _ReplicaList
  from jina.serve.networking.utils import DEFAULT_MINIMUM_RETRIES
  from jina.types.request import Request
  from jina.types.request.data import SingleDocumentRequest
label_desc: Use image node_id 5 for calling the GrpcConnectionPool obj's underlying member method code with example usage: obj.send_single_document_request(request, deployment, metadata, head, endpoint, timeout, retries) and returns: result_async_generator, None