-
Notifications
You must be signed in to change notification settings - Fork 209
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
Remove sync methods in core/ Glue struct, #1247
Conversation
Update Glue struct to provide async methods only. Apply the changes to existing codes (mainly test codes)
@panarch I created a PR to update pgwire examples to use latest gluesql, but I found that calling Are you aware of gluesql having compatibility issues with tokio? |
hello :) I think it's due to the failure to implement
You can check by simply implementing the following pub struct GluesqlProcessor {
db: SharedMemoryStorage,
}
#[async_trait(?Send)]
trait SendTest {
async fn query(&self, query: &str);
}
#[async_trait(?Send)] // success, but `#[async_trait]` fails.
impl SendTest for GluesqlProcessor {
async fn query(&self, query: &str) {
let db = self.db.clone();
let mut glue = Glue::new(db.clone());
let result = glue.execute(query).await;
println!("{:?}", result);
}
} We are working on some ideas to address this issue, but have not yet completed a functional implementation of Would appreciate your understanding on this point 😢 |
Update Glue struct to provide async methods only.
Apply the changes to existing codes (mainly test codes)