code: def test_set_request_id_headers_with_two_attributes(serve_instance):
      """Test that request id is set with X-Request-ID and RAY_SERVE_REQUEST_ID.
      x-request-id has higher priority.
      """
  
      @serve.deployment
      class Model:
          def __call__(self):
              request_id = (
                  ray.serve.context._serve_request_context.get().request_id
              )
              return request_id
  
      serve.run(Model.bind())
      resp = requests.get(
          "http://localhost:8000",
          headers={
              "X-Request-ID": "234",
          },
      )
  
      assert resp.status_code == 200
      assert "x-request-id" in resp.headers
      assert resp.text == resp.headers["x-request-id"]
  
file_path: ray/python/ray/serve/tests/test_http_headers.py
imports: import uuid
  import pytest
  import requests
  import starlette
  from fastapi import FastAPI
  import ray
  from ray import serve
label_desc: Use image node_id 2 for calling a global function with example usage: test_set_request_id_headers_with_two_attributes(serve_instance) and returns: request_id