felipecrv commented on issue #3454:
URL: https://github.com/apache/arrow-adbc/issues/3454#issuecomment-3316403315

   This is a nice way of convincing `rustc` nothing wrong is being done and 
drivers written in Rust could store some internal ID instead of aliasing the 
mutable pointer to the `Statement` like it's possible in Go/C/C++. A con is 
that it adds yet another object to the ADBC protocol.
   
   Another idea:
   
   ```rust
   let conn = database.new_connection();
   ...
   let stmt = conn.new_statement();
   ... 
   let stmt_id = stmt.id();  // standardize on a 128-bit byte string
   ...
   let reader = stmt.execute();
   ```
   
   While another thread can:
   
   ```
   database.cancel_stmt(stmt_id);
   ```
   
   Connections remain thread-confined. The database can track the statements 
for cancelling them. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to