setting up the stream