code: def _cached_get_request_session(
      max_retries,
      backoff_factor,
      backoff_jitter,
      retry_codes,
      raise_on_status,
      # To create a new Session object for each process, we use the process id as the cache key.
      # This is to avoid sharing the same Session object across processes, which can lead to issues
      # such as https://stackoverflow.com/q/3724900.
      _pid,
  ):
      """
      This function should not be called directly. Instead, use `_get_request_session` below.
      """
      assert 0 <= max_retries < 10
      assert 0 <= backoff_factor < 120
  
      retry_kwargs = {
          "total": max_retries,
          "connect": max_retries,
          "read": max_retries,
          "redirect": max_retries,
          "status": max_retries,
          "status_forcelist": retry_codes,
          "backoff_factor": backoff_factor,
          "backoff_jitter": backoff_jitter,
          "raise_on_status": raise_on_status,
      }
      urllib3_version = Version(urllib3.__version__)
      if urllib3_version >= Version("1.26.0"):
          retry_kwargs["allowed_methods"] = None
      else:
          retry_kwargs["method_whitelist"] = None
  
      if urllib3_version < Version("2.0"):
          retry = JitteredRetry(**retry_kwargs)
      else:
          retry = Retry(**retry_kwargs)
      adapter = HTTPAdapter(max_retries=retry)
      session = requests.Session()
      session.mount("https://", adapter)
      session.mount("http://", adapter)
      return session
  
file_path: mlflow/mlflow/utils/request_utils.py
imports: import os
  import random
  from functools import lru_cache
  import requests
  import urllib3
  from packaging.version import Version
  from requests.adapters import HTTPAdapter
  from requests.exceptions import HTTPError
  from urllib3.util import Retry
label_desc: Use image node_id 3 for calling a global function with example usage: _cached_get_request_session(max_retries, backoff_factor, backoff_jitter, retry_codes, raise_on_status, _pid) and returns: session