logStream writing coded to match