BUG-1668: split the writeout paths