Gregory Terzian

Results 388 comments of Gregory Terzian

Could this problem perhaps be solved with a side "shutdown" channel? In such a setup, on the receiving side, you select over a `recv` on your "main" channel and a...

I agree that an auxiliary channel is more complicated than calling a `stop` method, and I also think one could avoid adding features that could be implemented with basic building...

Here is an example of "communicating" between threads in the context of signal handling and interrupted threads: https://github.com/servo/servo/blob/5d479109ef3bdbf0d937f6ea318e9cce8bbde2b3/components/background_hang_monitor/sampler_linux.rs#L186 The corresponding signal handler is found at https://github.com/servo/servo/blob/5d479109ef3bdbf0d937f6ea318e9cce8bbde2b3/components/background_hang_monitor/sampler_linux.rs#L268 The code is actually...

> my goal here is not to spawn any additional threads for signal handling On second thoughts, I think actually the concept of "waiting" I introduced wouldn't work in practice,...

Perhaps a `Mutex` could be more appropriate to implement the shared data buffer. You could try to use a technique similar to graphics programming where you would swap buffers, see...

I'm thinking the maybe the problem is the call to `slot.wait_write()` inside `read`, at https://github.com/crossbeam-rs/crossbeam/blob/28ad2b7e015832b47db7e389dd9ebce3e94b3adb/crossbeam-channel/src/flavors/list.rs#L387 that then uses a backoff without ever blocking if it's completed, at https://github.com/crossbeam-rs/crossbeam/blob/28ad2b7e015832b47db7e389dd9ebce3e94b3adb/crossbeam-channel/src/flavors/list.rs#L56 Also note...

> Really the API that I am trying to mimic here is recv_max_timeout(n: usize, t: Duration). Which ideally receives up to the max specified events or times out before then...

@papertigers could you please try running your test with this PR and see if it helped at all? https://github.com/crossbeam-rs/crossbeam/pull/447

``` curl: (22) The requested URL returned error: 400 Bad Request make: *** [deploy] Error 22 ``` Is this the result of a failed check, or is there a problem...