Upgrade actix to 2.0 (fixes #392) #11
No reviewers
Labels
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Blocks
#13 Proxy pictshare requests (fixes #371)
LemmyNet/lemmy
Reference: LemmyNet/lemmy#11
Loading…
Reference in New Issue
No description provided.
Delete Branch "nutomic/lemmy:actix-2.0"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Cant say I understand the websocket code, but everything looks fine after these changes.
Docker build is failing, but that looks unrelated:
Noice. I'll get to this soon.
This is missing the stuff in the routes folder I think, which also need to be made async.
BTW so my other project I added this sync code shown on actix's r2d2 example here: https://github.com/actix/examples/blob/master/r2d2/src/main.rs#L15
I'm not sure how to do that
web::block
for the websockets, but it should be easy to add for the nodeinfo, feeds, etc.Okay I made the functions async, based on this example. Not sure how the database thing should work, do we really need to modify every single function that makes a database call?
FYI the Docker build issue is fixed by updating the version of
rust-musl-builder
in the Dockerfile. I will let you fix that to avoid having another open PR :phttps://github.com/tokio-rs/bytes/issues/323
Well the DB stuff always takes in &conn, so none of that's going to change at least.
I can handle this r2d2 stuff in another ticket tho, I made a issue for it here.
This looks good, imma test it shortly.