Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add session and task descriptions #208

Conversation

hishma
Copy link
Contributor

@hishma hishma commented Dec 17, 2023

This pull request updates the Apollo URLSessionClient adding the ability to optionally provide a session description and/or task description to the URLSession, and any subsequent URLSessionTask's created by the session.

These are helpful when debugging, especially when analyzing HTTP traffic with Instruments.

See also:

Provides an optional `sessionDescription` to the `URLSessionClient` initializer. If provided this will be added to the underlying `URLSession` to aid in debugging.

See: https://developer.apple.com/documentation/foundation/urlsession/1408277-sessiondescription
Provides an optional `taskDescription` to `URLSessionClient.sendRequest(_:_:_:_:)`.
If provided this will be added to the returned `URLSessionTask` where it can be used for debugging purposes.

See: https://developer.apple.com/documentation/foundation/urlsessiontask/1409798-taskdescription

Note: Not to be conflated with the `taskIdentifier`.
@apollo-cla
Copy link

@hishma: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/

Copy link

netlify bot commented Dec 17, 2023

👷 Deploy request for eclectic-pie-88a2ba pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 5b100e5

@hishma hishma closed this Dec 18, 2023
@hishma hishma deleted the session-and-task-descriptions branch December 18, 2023 15:39
@hishma hishma restored the session-and-task-descriptions branch February 29, 2024 15:43
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