You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/05/15 07:20:35 UTC

[GitHub] [arrow-rs] Max-Meldrum opened a new issue #290: Add Send to ArrayBuilder

Max-Meldrum opened a new issue #290:
URL: https://github.com/apache/arrow-rs/issues/290


   Problem:  I'm using a ``StructBuilder`` in [Arcon](https://github.com/cda-group/arcon) to build up Arrow tables.  The threading model ensures exclusive access to the builder but may move it across threads.  The main problem is that ``ArrayBuilder`` does not implement ``Send`` so it fails to compile..
   
   Solution:
   ```rust
   // Old
   pub trait ArrayBuilder: Any { .... }
   // New
   pub trait ArrayBuilder: Any + Send { .... }
   ```
   


-- 
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.

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



[GitHub] [arrow-rs] jorgecarleitao commented on issue #290: Add Send to ArrayBuilder

Posted by GitBox <gi...@apache.org>.
jorgecarleitao commented on issue #290:
URL: https://github.com/apache/arrow-rs/issues/290#issuecomment-841616013


   Thanks for this.
   
   Honest curiosity: what is the use-case where the ArrayBuilder is passed around?
   
   Also, isn't it possible to use `&dyn ArrayBuilder + Send` on the code to enforce this?


-- 
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.

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



[GitHub] [arrow-rs] alamb closed issue #290: Add Send to ArrayBuilder

Posted by GitBox <gi...@apache.org>.
alamb closed issue #290:
URL: https://github.com/apache/arrow-rs/issues/290


   


-- 
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.

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



[GitHub] [arrow-rs] alamb closed issue #290: Add Send to ArrayBuilder

Posted by GitBox <gi...@apache.org>.
alamb closed issue #290:
URL: https://github.com/apache/arrow-rs/issues/290


   


-- 
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.

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



[GitHub] [arrow-rs] Max-Meldrum commented on issue #290: Add Send to ArrayBuilder

Posted by GitBox <gi...@apache.org>.
Max-Meldrum commented on issue #290:
URL: https://github.com/apache/arrow-rs/issues/290#issuecomment-841617101


   > Thanks for this.
   > 
   > Honest curiosity: what is the use-case where the ArrayBuilder is passed around?
   > 
   > Also, isn't it possible to use `&dyn ArrayBuilder + Send` on the code to enforce this?
   
   Well it is not so much the ArrayBuilder being sent around, but it is a StructBuilder that is passed around which itself contains a bunch of field builders of ``Box<ArrayBuilder>``.  The use case is that a ``StructBuilder`` is used to build up columnar data in a streaming window. During the length of this window, the "worker" may move across threads as the underlying thread model uses a workstealing scheduler.
   


-- 
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.

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



[GitHub] [arrow-rs] jorgecarleitao commented on issue #290: Add Send to ArrayBuilder

Posted by GitBox <gi...@apache.org>.
jorgecarleitao commented on issue #290:
URL: https://github.com/apache/arrow-rs/issues/290#issuecomment-841628601


   makes sense, thanks!


-- 
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.

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