obelix74 opened a new pull request, #3414:
URL: https://github.com/apache/polaris/pull/3414

   ## Checklist
   - [x] ๐Ÿ›ก๏ธ Don't disclose security issues! (contact [email protected])
   - [x] ๐Ÿ”— Clearly explained why the changes are needed, or linked related 
issues: Fixes #
   - [x] ๐Ÿงช Added/updated tests with good coverage, or manually tested (and 
explained how)
   - [x] ๐Ÿ’ก Added comments for complex logic
   - [ ] ๐Ÿงพ Updated `CHANGELOG.md` (if needed)
   - [ ] ๐Ÿ“š Updated documentation in `site/content/in-dev/unreleased` (if needed)
   
   Fixes a part of https://github.com/apache/polaris/issues/3337
   
   This change enables deterministic correlation between:
   - Catalog operations (Polaris events)
   - Credential vending (AWS CloudTrail via STS session tags)
   - Metrics reports from compute engines (Spark, Trino, etc.)
   
   Changes:
   1. Add traceId field to CredentialVendingContext
      - Marked with @Value.Auxiliary to exclude from cache key comparison
      - Every request has unique trace ID, so including it in equals/hashCode 
would prevent all cache hits
      - Trace ID is for correlation/audit only, not authorization
   
   2. Extract OpenTelemetry trace ID in StorageAccessConfigProvider
      - getCurrentTraceId() extracts trace ID from current span context
      - Populates CredentialVendingContext.traceId for each request
   
   3. Add trace_id to AWS STS session tags
      - AwsSessionTagsBuilder includes trace_id in session tags
      - Appears in CloudTrail logs for correlation with catalog operations
      - Uses 'unknown' placeholder when trace ID is not available
   
   4. Update tests to verify trace_id is included in session tags
   
   This enables operators to correlate:
   - Which catalog operation triggered credential vending
   - Which data access events in CloudTrail correspond to catalog operations
   - Which metrics reports correspond to specific catalog operations
   
   


-- 
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