Log.Warning($"[PeriodicFileSystemWatcher.CheckSourceFolder] Find '{file}' does not exists");
continue;
}
Log.Debug($"[PeriodicFileSystemWatcher.CheckSourceFolder] Find new file {file}");
if(FSUtils.IsFileLocked(newFileInfo(file)))
{
continue;
}
stringtempFile;
try
try
{
{
Log.Debug($"[PeriodicFileSystemWatcher.CheckSourceFolder] Find new file {file}");
tempFile=MoveToTemporary(file);
if(FSUtils.IsFileLocked(newFileInfo(file)))
if(string.IsNullOrWhiteSpace(tempFile))
{
continue;
}
stringtempFile;
try
{
{
tempFile=MoveToTemporary(file);
Log.SystemWarning($"[PeriodicFileSystemWatcher.CheckSourceFolder] Failed to move file '{file}' to temporary directory '{_temporaryFolder}'. Without system error!");
if(string.IsNullOrWhiteSpace(tempFile))
{
Log.SystemWarning($"[PeriodicFileSystemWatcher.CheckSourceFolder] Failed to move file '{file}' to temporary directory '{_temporaryFolder}'. Without system error!");
continue;
}
}
catch(Exceptionex)
{
Log.SystemError(ex,$"[PeriodicFileSystemWatcher.CheckSourceFolder] Failed to attempt to move file '{file}' to temporary directory '{_temporaryFolder}'");
Log.SystemError(ex,$"[PeriodicFileSystemWatcher.CheckSourceFolder] Failed to attempt to move file '{file}' to temporary directory '{_temporaryFolder}'");