close-semantics and a way to signal the reader thread