Skip to content

Update RemoteOrchestrationServiceClient.cs#1032

Merged
shankarsama merged 1 commit intoAzure:mainfrom
maximecaron:main
Feb 12, 2024
Merged

Update RemoteOrchestrationServiceClient.cs#1032
shankarsama merged 1 commit intoAzure:mainfrom
maximecaron:main

Conversation

@maximecaron
Copy link
Contributor

"Refactored Exception Handling in Retry Logic for RemoteOrchestrationServiceClient

The DurableTask.AzureServiceFabric NuGet package was previously using HttpWebRequest (.NET 4) and has since been updated to use HttpClient. However, the associated exception handling in the retry logic was not updated accordingly.

Originally, the catch block was designed to handle WebException, a legacy exception type associated with HttpWebRequest. HttpClient, however, throws HttpRequestException for request-related issues, not WebException.

This oversight led to the retry logic failing to function as intended, as it was not catching the correct exception type. This is particularly critical for the RemoteOrchestrationServiceClient, which relies on this retry mechanism to detect changes in the SF partition leader.

This commit updates the catch block to handle HttpRequestException, aligning with the HttpClient usage and restoring the intended functionality of the retry logic."

"Refactored Exception Handling in Retry Logic for RemoteOrchestrationServiceClient

The DurableTask.AzureServiceFabric NuGet package was previously using HttpWebRequest (.NET 4) and has since been updated to use HttpClient. However, the associated exception handling in the retry logic was not updated accordingly.

Originally, the catch block was designed to handle WebException, a legacy exception type associated with HttpWebRequest. HttpClient, however, throws HttpRequestException for request-related issues, not WebException.

This oversight led to the retry logic failing to function as intended, as it was not catching the correct exception type. This is particularly critical for the RemoteOrchestrationServiceClient, which relies on this retry mechanism to detect changes in the SF partition leader.

This commit updates the catch block to handle HttpRequestException, aligning with the HttpClient usage and restoring the intended functionality of the retry logic."
@shankarsama shankarsama merged commit cdee763 into Azure:main Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants