Function
select-with-timeout
Blocks until one of the given objects is ready for I/O, or the timeout expires.
If an object is ready, the I/O action is guaranteed to complete without blocking.
Valid object handles includes bodies and pending requests. See the async-io.pollable
definition for more details, including what I/O actions are associated with each handle
type.
The timeout is specified in milliseconds.
Returns the index (not handle!) of the first object that is ready, or none if the
timeout expires before any objects are ready for I/O.
select-with-timeout: func(handles: list<borrow<pollable>>, timeout-ms: u32) -> option<u32>;