-
Notifications
You must be signed in to change notification settings - Fork 45
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
Usage with axum difficult #9
Comments
A possible easy fix is probably to just not force it to be a reference and let the implementer decide if this should be a reference or not. That way this would offer the best of both worlds. (Basically moving the reference to the type definition when implementing instead of forcing it always) |
I looked at your If you want to add axum support to this crate, you should instead use feature flags, with one feature I suggest you work on this in a pull request to this repo, and only commit small changes each time. That way it will be much easier to follow along and help out if you get stuck somewhere. |
Ah sorry yeah shouldn't have this written late at night yesterday 😅 I will clear the git up later today or tomorrow and come back but the short version is that I basically took the example and tried to use axum instead of actix. Therefor I had to port the middleware to axum as that also is (logically) actix Web specific. I can probably work on a pr for axum as well. :) will have a look later today. |
Just wanted to note that I started work on this now :) Its not pushed yet but I will keep you updated/open the PR when its ready |
I think this should be closed, the only remaining issue with axum is that we still need to run on the actix runtime but this should be fixed by making the @MTRNord here is my project if you need to take a look at a working example: https://github.com/oknozor/gill |
Hi I am trying to use this with axum instead of axtix-web.
However it seems that
into_apub
fromApubObject
causes:I assume this is because the function takes an reference to the Arc instead of taking the arc itself which somewhat breaks the Arc's purpose.
Is there any way this could be made axum compatible?
My (broken) Code for this is available here (it also wont compile due to some other reasons as I am in between adding basic functions but got stuck on this issue): https://gitlab.com/MTRNord/pixelrust/-/blob/dc50d4bd729eecc23d972d6d3d92426edb280911/src/instance.rs#L132
The text was updated successfully, but these errors were encountered: