close tap writer streams when filename is specified