local file saving implemented for tmp files (that matched by pattern)
fixed metadata file naming