class_docstr: Placeholder docstring
class_docstr_tok: ["Placeholder","docstring"]
docstr: Placeholder docstring
docstr_tok: ["Placeholder","docstring"]
code: def _invoke_djl_serving(
      self, request: object, content_type: str, accept: str
  ):
      """Placeholder docstring"""
      try:
          response = requests.post(
              f"http://{get_docker_host()}:8080/predictions/model",
              data=request,
              headers={"Content-Type": content_type, "Accept": accept},
              timeout=300,
          )
          response.raise_for_status()
          return response.content
      except Exception as e:
          raise Exception(
              "Unable to send request to the local container server %s",
              str(e),
          )
  
file_path: sagemaker-python-sdk/src/sagemaker/serve/model_server/djl_serving/server.py
imports: from __future__ import absolute_import
  import requests
  import logging
  from pathlib import Path
  from docker.types import DeviceRequest
  from sagemaker import Session, fw_utils
  from sagemaker.serve.utils.exceptions import LocalModelInvocationException
  from sagemaker.base_predictor import PredictorBase
  from sagemaker.s3_utils import determine_bucket_and_prefix, parse_s3_url, s3_path_join
  from sagemaker.s3 import S3Uploader
  from sagemaker.local.utils import get_docker_host
label_desc: Use image node_id 2 for calling the LocalDJLServing obj's underlying member method code with example usage: obj._invoke_djl_serving(request, content_type, accept) and returns: response