Added threading to Stream Processor