Skip to content

Replace ws-rs with async-tungstenite. - #27164

Merged
bors-servo merged 1 commit into
servo:masterfrom
jdm:tungstenite
Jul 8, 2020
Merged

bors-servo merged 1 commit into
servo:masterfrom
jdm:tungstenite

Conversation

@jdm

@jdm jdm commented Jul 3, 2020 •

Copy link
Copy Markdown
Member

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.


@highfive

highfive commented Jul 3, 2020

Copy link
Copy Markdown

Heads up! This PR modifies the following files:

  • @KiChjang: components/net/Cargo.toml, components/net/resource_thread.rs, components/net/websocket_loader.rs

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Jul 3, 2020
@@ -0,0 +1,3 @@
[third-party-cookie-accepted.https.html]

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new test failure shows up because tungstenite correctly passes through multiple Set-Cookie headers in the WS response, whereas ws-rs appears to silently drop all but the first.

@jdm

jdm commented Jul 3, 2020

Copy link
Copy Markdown
Member Author

r? @nox
Do you want to take a look at this?

@highfive highfive assigned nox and unassigned SimonSapin Jul 3, 2020
@nox

nox commented Jul 3, 2020

Copy link
Copy Markdown
Contributor

This looks cool! Will review on Monday!

@jdm

jdm commented Jul 3, 2020

Copy link
Copy Markdown
Member Author

@bors-servo try=wpt

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Trying commit bed15c7 with merge 659d1b4...

bors-servo added a commit that referenced this pull request Jul 3, 2020
Replace ws-rs with async-tungstenite.

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27043
- [x] There are tests for these changes
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - status-taskcluster

@highfive highfive added the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@highfive highfive removed the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@jdm

jdm commented Jul 3, 2020

Copy link
Copy Markdown
Member Author

@bors-servo try=wpt

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Trying commit 7376630 with merge 1a8e80f...

bors-servo added a commit that referenced this pull request Jul 3, 2020
Replace ws-rs with async-tungstenite.

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27043
- [x] There are tests for these changes
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - status-taskcluster

@highfive highfive added the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@jdm

jdm commented Jul 3, 2020

Copy link
Copy Markdown
Member Author

Ok, the test failures appear to be related to the host replacement that happens for WPT which confuses openssl. I need to figure out what we do differently in HTTPS code that allows it to work.

@highfive highfive removed the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@jdm

jdm commented Jul 3, 2020

Copy link
Copy Markdown
Member Author

@bors-servo try=wpt

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Trying commit 806133d with merge e05cc5c...

bors-servo added a commit that referenced this pull request Jul 3, 2020
Replace ws-rs with async-tungstenite.

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27043
- [x] There are tests for these changes
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - status-taskcluster

@highfive highfive added the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@highfive highfive removed the S-tests-failed The changes caused existing tests to fail. label Jul 3, 2020
@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Jul 8, 2020
@jdm

jdm commented Jul 8, 2020

Copy link
Copy Markdown
Member Author

@bors-servo retry

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit 76198e4 with merge f5666f7...

bors-servo added a commit that referenced this pull request Jul 8, 2020
Replace ws-rs with async-tungstenite.

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27043
- [x] There are tests for these changes
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Jul 8, 2020
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - status-taskcluster

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Jul 8, 2020
@jdm

jdm commented Jul 8, 2020

Copy link
Copy Markdown
Member Author

@bors-servo retry

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit 76198e4 with merge d6e29a8...

bors-servo added a commit that referenced this pull request Jul 8, 2020
Replace ws-rs with async-tungstenite.

This change moves us from ws-rs (which doesn't see a lot of maintainer activity) and its custom async implementation to tungstenite and the tokio ecosystem. This is particularly important because of #27043, which breaks SSL websockets on Windows.

Depends on sdroege/async-tungstenite#40.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27043
- [x] There are tests for these changes
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Jul 8, 2020
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - status-taskcluster

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Jul 8, 2020
@jdm

jdm commented Jul 8, 2020

Copy link
Copy Markdown
Member Author

@bors-servo retry

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit 76198e4 with merge ed82722...

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Jul 8, 2020
@bors-servo

Copy link
Copy Markdown
Contributor

☀️ Test successful - status-taskcluster
Approved by: nox
Pushing ed82722 to master...

@bors-servo
bors-servo merged commit ed82722 into servo:master Jul 8, 2020
@highfive highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Jul 8, 2020
bors-servo added a commit that referenced this pull request Jul 16, 2020
Remove explicit Host header from websocket connection.

This was a regression from #27164, and fixing it allows hubs.mozilla.com to work again.
bors-servo added a commit that referenced this pull request Jul 16, 2020
Remove explicit Host header from websocket connection.

This was a regression from #27164, and fixing it allows hubs.mozilla.com to work again.
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.

Generic websocket error when connecting over WSS using UWP

5 participants