rpc: use count of pipe openers to wait for first open