async fn write_n<T: Serialize>( writer: &mut SnapshotPayloadWriter, data: &[T], ) -> BackupResult<()>