rust-lang / rust-playground

The Rust Playground
https://play.rust-lang.org/
Apache License 2.0
1.25k stars 206 forks source link

Investigate moving to a new web framework #269

Closed shepmaster closed 2 years ago

shepmaster commented 6 years ago

Iron is no longer actively maintained. Now is when we can see if our architecture separation pays off or not...

How can I help?

In order of difficulty from easy to hard...

What are you looking at?

Requirements

Caching

The playground serves up index.html and a few other similar files that never change name. These should ideally use something like ETags with a short-ish expiry. We currently use a 1 hour expiry, but not ETags.

The assets are all in a path called /assets. These all have a digest hash appended to them, so they can be cached "forever". In practice, this is 1 year.

There's a few other pieces of information that could use caching (e.g. the playground crates, channel versions) but these are all generated data and so we could pre-compute an ETags identifier to check against.

Access statistics

shepmaster commented 6 years ago

Gotham

fafhrd91 commented 6 years ago

did you consider actix ? only feature actix is missing - "url rewriting"

shepmaster commented 6 years ago

@fafhrd91 I have not really considered it. Speaking plainly, your incessant advertising of actix in almost every place I read about Rust (Gitter, Reddit, Hacker News, etc.) makes me less inclined to try it. I, so far, have no technical opinions about it and haven't ruled it in or out.

fafhrd91 commented 6 years ago

fair point. in that case Gotham is better choice I guess.

shepmaster commented 4 years ago

Tower Web

To be determined...

shepmaster commented 4 years ago

Warp

To be determined...

shepmaster commented 4 years ago

Actix web

To be determined...

shepmaster commented 4 years ago

Thruster

To be determined...

shepmaster commented 4 years ago

Tide

To be determined...

shepmaster commented 3 years ago

Axum

To be determined...

shepmaster commented 2 years ago

I've merged in an implementation using Axum. As of a few hours ago, I've enabled the Axum feature flag on play.rust-lang.org. Assuming nothing drastic happens that cannot be fixed, I'll eventually move completely over.

shepmaster commented 2 years ago

Closed in #799