birschick-bq commented on code in PR #3022:
URL: https://github.com/apache/arrow-adbc/pull/3022#discussion_r2187765096


##########
csharp/src/Drivers/BigQuery/BigQueryStatement.cs:
##########
@@ -302,25 +331,27 @@ private IArrowType GetType(TableFieldSchema field, 
IArrowType type)
             return type;
         }
 
-        private IArrowReader? 
ReadChunkWithRetries(TokenProtectedReadClientManger clientMgr, string 
streamName)
+        private IArrowReader? 
ReadChunkWithRetries(TokenProtectedReadClientManger clientMgr, string 
streamName, Activity? activity)
         {
-            Func<Task<IArrowReader?>> func = () => 
Task.FromResult<IArrowReader?>(ReadChunk(clientMgr, streamName));
-            return 
RetryManager.ExecuteWithRetriesAsync<IArrowReader?>(clientMgr, func, 
MaxRetryAttempts, RetryDelayMs).GetAwaiter().GetResult();
+            Func<Task<IArrowReader?>> func = () => 
Task.FromResult<IArrowReader?>(ReadChunk(clientMgr, streamName, activity));
+            return 
RetryManager.ExecuteWithRetriesAsync<IArrowReader?>(clientMgr, func, activity, 
MaxRetryAttempts, RetryDelayMs).GetAwaiter().GetResult();
         }
 
-        private static IArrowReader? ReadChunk(TokenProtectedReadClientManger 
clientMgr, string streamName)
+        private static IArrowReader? ReadChunk(TokenProtectedReadClientManger 
clientMgr, string streamName, Activity? activity)
         {
-            return ReadChunk(clientMgr.ReadClient, streamName);
+            return ReadChunk(clientMgr.ReadClient, streamName, activity);
         }
 
-        private static IArrowReader? ReadChunk(BigQueryReadClient client, 
string streamName)
+        private static IArrowReader? ReadChunk(BigQueryReadClient client, 
string streamName, Activity? activity)
         {
             // Ideally we wouldn't need to indirect through a stream, but the 
necessary APIs in Arrow
             // are internal. (TODO: consider changing Arrow).
+            activity?.AddBigQueryTag("read_stream", streamName);

Review Comment:
   @CurtHagenlocher / @davidhcoe 
   
   It seems OTel 
   has described the need to be careful, but the only concrete action seems to 
be to have filters/scrubbers on the OTel Collector via a processor.
   https://opentelemetry.io/docs/security/handling-sensitive-data/
   
   I believe we'll need to add overloads to scrub/anonymize potential PII data.



-- 
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: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to