refactor content and metadata extraction within FTSWriteAction