Skip to content

Remove incorrect [Obsolete] from DataServiceContext.Timeout#3498

Draft
Copilot wants to merge 2 commits intomainfrom
copilot/fix-issue-3494
Draft

Remove incorrect [Obsolete] from DataServiceContext.Timeout#3498
Copilot wants to merge 2 commits intomainfrom
copilot/fix-issue-3494

Conversation

Copy link
Copy Markdown

Copilot AI commented Mar 8, 2026

DataServiceContext.Timeout was marked obsolete with a message directing users to "use IHttpClientFactory" — but IHttpClientFactory is an interface, not a property, leaving no actionable migration path. The property is still fully functional: it sets a per-request timeout that flows through RequestInfoODataRequestMessageWrapperHttpClientRequestMessage.Timeout. The obsolete attribute also caused a CS0618 warning inside RequestInfo.cs where the library calls this.Context.Timeout internally.

Changes

  • DataServiceContext.cs: Remove [Obsolete] from Timeout property; update XML docs to clarify:
    • Per-request timeout via Timeout remains the primary mechanism
    • HttpClientFactory can be used to configure a shared HttpClient.Timeout for all requests
    • When both are set, the per-request Timeout takes precedence

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

…property

Co-authored-by: xuzhg <9426627+xuzhg@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix issue #3494 Remove incorrect [Obsolete] from DataServiceContext.Timeout Mar 8, 2026
Copilot finished work on behalf of xuzhg March 8, 2026 18:27
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