private static void S3ToFS(AttachmentBE[] attachmentList) { XDoc s3config = new XDoc("config") .Start("publickey").Value(_public_key).End() .Start("privatekey").Value(_private_key).End() .Start("bucket").Value(_default_bucket).End() .Start("prefix").Value(_prefix).End(); S3Storage s3 = new S3Storage(s3config); XDoc fsconfig = new XDoc("config") .Start("path").Value(_attachmentPath).End(); FSStorage fs = new FSStorage(fsconfig); transferFiles(attachmentList, s3, fs); }
private static void FSToS3(ResourceBE[] attachmentList) { XDoc s3config = new XDoc("config") .Start("publickey").Value(_public_key).End() .Start("privatekey").Value(_private_key).End() .Start("bucket").Value(_default_bucket).End() .Start("prefix").Value(_prefix).End(); S3Storage s3 = new S3Storage(s3config, LogUtils.CreateLog<S3Storage>()); XDoc fsconfig = new XDoc("config") .Start("path").Value(_attachmentPath).End(); FSStorage fs = new FSStorage(fsconfig); transferFiles(attachmentList, fs, s3); }