You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Would you be willing to accept a contribution implementing SASL/OAUTHBEARER support? This should be relatively simple, especially now that the library depends on rsasl.
The only wrinkle is that this would probably need to contain some form of callback, since on reconnect the client would likely need to request a new token. This callback should probably be async, since it will usually involve some form of async operation. This means async_trait or, if you would prefer to avoid that dependency, requiring users to box their futures themselves with a trait returning Pin<Box<dyn Future<Output = ...> + 'static>>.
Thoughts? I would be willing contribute this, but I'd rather nail down the approach you prefer first.
The text was updated successfully, but these errors were encountered:
Would you be willing to accept a contribution implementing SASL/OAUTHBEARER support? This should be relatively simple, especially now that the library depends on rsasl.
Yes, PRs are welcome 🙂
The only wrinkle is that this would probably need to contain some form of callback, since on reconnect the client would likely need to request a new token. This callback should probably be async, since it will usually involve some form of async operation. This means async_trait or, if you would prefer to avoid that dependency, requiring users to box their futures themselves with a trait returning Pin<Box<dyn Future<Output = ...> + 'static>>.
I think if it's really just one method, Pin<Box<...>> sounds good enough. You can also use BoxFuture since this is a rather well-known type. To turn this into an actual function (and since async closures aren't available on stable yet), you probably need something like:
Would you be willing to accept a contribution implementing SASL/OAUTHBEARER support? This should be relatively simple, especially now that the library depends on
rsasl
.The only wrinkle is that this would probably need to contain some form of callback, since on reconnect the client would likely need to request a new token. This callback should probably be async, since it will usually involve some form of async operation. This means
async_trait
or, if you would prefer to avoid that dependency, requiring users to box their futures themselves with a trait returningPin<Box<dyn Future<Output = ...> + 'static>>
.Thoughts? I would be willing contribute this, but I'd rather nail down the approach you prefer first.
The text was updated successfully, but these errors were encountered: