msrathore-db opened a new pull request, #3618:
URL: https://github.com/apache/arrow-adbc/pull/3618

   ## Summary
   Adds Activity-based logging to `RetryHttpHandler.cs` for improved 
observability of HTTP retry behavior.
   
   ## Changes
   
   ### Logging Strategy: Minimal
   
   - ✅ **No logging for successful requests** (most common case - ~99%)
   - ✅ **Minimal logging only when retries occur**
   - ✅ **Summary logging for terminal failures**
   
   ### What Gets Logged
   
   **Tags (Only When Retries Occur):**
   1. `http.retry.total_attempts` - Number of retry attempts
   2. `http.response.status_code` - Final HTTP status code
   3. `http.retry.outcome` - Only for failures: `cancelled` or 
`timeout_exceeded`
   
   **Retryable Status Codes:** 408, 502, 503, 504
   
   ### What Is NOT Logged
   
   To minimize overhead:
   - ❌ Individual retry attempts
   - ❌ Wait times and backoff strategies
   - ❌ Retry-After header parsing
   - ❌ Request URIs
   - ❌ Per-attempt events
   
   ### Example Log Output
   
   **Success (No Retries):**
   ```json
   // NO LOGGING - Most efficient path
   ```
   
   **Success After Retries:**
   ```json
   {
     "Tags": {
       "http.retry.total_attempts": 3,
       "http.response.status_code": 200
     }
   }
   ```
   
   **Timeout Exceeded:**
   ```json
   {
     "Tags": {
       "http.retry.total_attempts": 5,
       "http.response.status_code": 503,
       "http.retry.outcome": "timeout_exceeded"
     }
   }
   ```
   
   ## Testing
   
   Tested locally with logging examples.
   
   ## Breaking Changes
   
   None. Additive logging only.


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