#xwt

37 messages · Page 1 of 1 (latest)

craggy rose
#

A unified WebTransport API that you can use for browser/native cross platform apps. Originally to power the networking layer of the games made with the bevy engine - but can be applied elsewhere too.
By @leaden wind https://github.com/MOZGIII/xwt

GitHub

A unified WebTransport API that you can use for browser/native cross platform apps. Originally to power the networking layer of the games made with the bevy engine - but can be applied elsewhere to...

leaden wind
#

I'll be around to chat and help with issues regarding xwt.

ember mirage
# leaden wind I'll be around to chat and help with issues regarding `xwt`.

Wow, such great work here, thank you 🙂

Do you you have any docs to help run the tests?

I understand the focus here is on running native/wasm WebTransport clients, but does anything in this crate help you run a WT Server? What would your recommendations be for crates to help you do that / what setup are you using for your own development?

Thank you 🙏

leaden wind
#

For the server I'd recommend using wtransport

#

xwt is indeed more focus on the clientside right now, although the server support is present too - but it is not tested or used anywhere afaik.
The wtransport really aim to be a one-stop-shop for the native clients, but I also use a crate for rustls certificates reloader, as in my production certificates automatically refreshed from let's encrypt by kubernetes - so my app just has to reload them often enough.

Overall, there are a bunch of crates that implement networking for bevy on top of xwt, like the lightyear and aesocket - consider using those instead of the low-level xwt

#

Also it is now possible to add support for xwt to bevy_replicon - although is has not yet been done

ember mirage
# leaden wind Also it is now possible to add support for xwt to bevy_replicon - although is ha...

Thanks for the info 🙂 yeah I'm investigating how to go about adding a WT transport layer to my networking library naia ..

when I looked at doing this in the past, it seemed that there would be a bit more research/dev I'd need to do to automate away all the cert management stuff from the users of my library .. I'd like to be able to never think about it server-side or client-side ..

Anyway, I'm still curious what steps are necessary for running the tests (including the test server) in xwt, also what fiddling I need to do with certs, I'd like to use a Rust crate or write my own to refresh certs instead of having to rely on kubernetes.

Thanks for any help / advice 🙏

leaden wind
#

cargo run to run the test server

#

Then cargo test to run tests while the server is running

#

cargo test --target wasm32-unknown-unknown to test wasm (will run a browser under the hood)

#

You can also peek at what the CI is doing

ember mirage
#

that simple hm? awesome thank you 🙂

leaden wind
#

Yep, I tried to make it really easy for everyone's benefit 😄

gritty ridge
gritty ridge
leaden wind
#

This is actually most likely the issue with the server-side

#

Firefox requires some special response from the server, I don't recall exactly - but please report this to wtransport

leaden wind
#

But you could alsp parse the certificate from pem and use a sha256 sum of its der form - so you'd only need the certificate itself, and not its hashes

gritty ridge
# leaden wind But you could alsp parse the certificate from pem and use a sha256 sum of its de...
GitHub

A unified WebTransport API that you can use for browser/native cross platform apps. Originally to power the networking layer of the games made with the bevy engine - but can be applied elsewhere to...

leaden wind
ember mirage
#

Man that helps a lot, thank you for all this work! 💪

Quick question - do you know of any reason (other than the fact xwt is still WIP) you might not want to use the test crates like xwt-test-assets-build xwt-test-assets & xwt-test-server in production?

I'm just wondering why the names indicate they are only for testing, and if anything fundamentally different would need to be done in production. Thank you 🙏

leaden wind
#

They'll generate certificates and cache thme in the build tree that expire in two weeks; they also bring them into the binary images are burnt in constants - so, very unfit for production

#

Also private key is also burnt-in to the client binary - you woun't want that for production apps

#

Btw, I have found pretty odd delays while testing examples with Chrome; no idea at all if the issue is with Chrome implementation of WebTransport, the wtransport server or somewhere in the xwt or the example code itself

gritty ridge
#

Hi is it possible to update the timeout of the webtransport connection at runtime?

leaden wind
#

On native yes, on web no way to alter it at all

gritty ridge
leaden wind
#

Yeah, not for the established connections

#

But it can be addrd if needed

#

There are also different timeouts, some of them can be changed for a quic connection, some of them can't, and some just don't make sense after the connection is established

#

Referring to keepalive timeout

leaden wind
leaden wind
leaden wind
#

Did you know we made https://docs.rs/web-wt-sys ? If you need only WebTransport API in Web WASM and as low-level as possible - this is a better way to go than the xwt crates. Is it still a part of the xwt repo and maintained together with the rest of xwt crates.