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

Execute websocket failure on secure tunnel event loop #104

Closed
wants to merge 10 commits into from

Conversation

sfod
Copy link
Contributor

@sfod sfod commented Dec 28, 2023

Host resolution failure could lead to a WebSocket setup callback to be called on a different thread than secure tunnel event loop uses. Use a cross-thread task to handle that particular case.

This PR helps with aws/aws-iot-device-sdk-cpp-v2#669

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@sfod sfod marked this pull request as ready for review December 28, 2023 22:38
@sbSteveK
Copy link
Contributor

sbSteveK commented Jan 5, 2024

This looks good but I'm gonna hold off on approving because I think we may need to implement a fix in aws-c-http. On the creation of the websocket via aws_websocket_client_connect we pass along options that include requested_event_loop. This should force everything the websocket is doing and/or failing to the provided event loop. The fix here insures we stay on that loop but if it's broken here, it's possible we could be running into similar issues with websocket elsewhere.

Notes:
We originally implemented event loop assignment here: awslabs/aws-c-http#391

@sfod
Copy link
Contributor Author

sfod commented Jan 9, 2024

Closing in favor of awslabs/aws-c-io#618

@sfod sfod closed this Jan 9, 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.

3 participants