You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by "bryancall (via GitHub)" <gi...@apache.org> on 2025/12/05 00:14:00 UTC
[PR] Fix retry logic for TSHttpTxnServerAddrSet (issue #12611) [trafficserver]
bryancall opened a new pull request, #12733:
URL: https://github.com/apache/trafficserver/pull/12733
When a plugin uses TSHttpTxnServerAddrSet() to set a server address and the connection fails, ATS should retry by calling the OS_DNS hook again to allow the plugin to provide an alternative address. However, the retry logic was missing handling for the USE_API case.
**Changes:**
- Added retry handling for ResolveInfo::OS_Addr::USE_API in handle_response_from_server()
- Clears dns_info.resolved_p to trigger OS_DNS hook re-execution
- Resets os_addr_style to TRY_DEFAULT to allow normal flow
- Clears server_request to allow it to be rebuilt for new destination
- Added api_server_addr_set_retried flag to prevent infinite retry loops
- Added test plugin and autest to verify the fix
- Updated TSHttpTxnServerAddrSet documentation to clarify retry behavior
Fixes #12611
--
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-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix retry logic for TSHttpTxnServerAddrSet (issue #12611) [trafficserver]
Posted by "bneradt (via GitHub)" <gi...@apache.org>.
bneradt commented on PR #12733:
URL: https://github.com/apache/trafficserver/pull/12733#issuecomment-4422753988
10.1.x via: https://github.com/apache/trafficserver/pull/13155
--
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-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix retry logic for TSHttpTxnServerAddrSet (issue #12611) [trafficserver]
Posted by "cmcfarlen (via GitHub)" <gi...@apache.org>.
cmcfarlen commented on PR #12733:
URL: https://github.com/apache/trafficserver/pull/12733#issuecomment-4423511264
Cherry-picked to 10.1.x branch
--
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-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix retry logic for TSHttpTxnServerAddrSet (issue #12611) [trafficserver]
Posted by "bryancall (via GitHub)" <gi...@apache.org>.
bryancall commented on PR #12733:
URL: https://github.com/apache/trafficserver/pull/12733#issuecomment-3614826428
**Why limit to 1 retry:**
The retry logic intentionally allows only one additional OS_DNS hook call rather than using `connect_attempts_max_retries`. This avoids a combinatorial explosion of connection attempts:
- With 1 OS_DNS retry and `connect_attempts_max_retries=3`: up to 6 total connection attempts (2 addresses × 3 retries each)
- If we used `connect_attempts_max_retries` for OS_DNS retries too: up to 12 attempts (4 addresses × 3 retries each)
The single retry gives the plugin one opportunity to provide an alternative address on connection failure, which matches what issue #12611 requested. This keeps latency bounded while still enabling the documented retry behavior.
--
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-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix retry logic for TSHttpTxnServerAddrSet (issue #12611) [trafficserver]
Posted by "bryancall (via GitHub)" <gi...@apache.org>.
bryancall merged PR #12733:
URL: https://github.com/apache/trafficserver/pull/12733
--
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-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org