shunping commented on code in PR #34062:
URL: https://github.com/apache/beam/pull/34062#discussion_r1970282106


##########
sdks/python/apache_beam/io/gcp/gcsio.py:
##########
@@ -125,14 +126,32 @@ def create_storage_client(pipeline_options, 
use_credentials=True):
     from google.api_core import client_info
     beam_client_info = client_info.ClientInfo(
         user_agent="apache-beam/%s (GPN:Beam)" % beam_version.__version__)
+
+    # Note: Custom audit entries with "job" key will overwrite this default.
+    extra_headers = {
+        "x-goog-custom-audit-job": google_cloud_options.job_name
+        if google_cloud_options.job_name else "UNKNOWN"

Review Comment:
   The job name field is added in a PR last year: #31300. While job name can be 
determined before the job submission, job id cannot. That's why we cannot use 
job id here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to