in AdlsDotNetSDK/FileProperties/PropertyManager.cs [227:262]
private void ConsumerRun()
{
while (true)
{
if (_cancelToken.IsCancellationRequested)
{
return;
}
var job = ConsumerQueue.Poll();
if (GetException() != null || job == null || job is PoisonJob)
{
ConsumerQueue.Add(new PoisonJob());
return;
}
try
{
job.DoRun(PropertyJobLog);
}
catch (AdlsException ex)
{
if (ex.HttpStatus != HttpStatusCode.NotFound)//Do not stop acl processor if the file/directory is deleted
{
SetException(ex);//Sets the global exception to signal other threads to close
ConsumerQueue.Add(new PoisonJob());//Handle corner cases like when exception is raised other threads can be in wait state
return;
}
}
catch (Exception ex)
{
SetException(ex);
ConsumerQueue.Add(new PoisonJob());//Handle corner cases like when exception is raised other threads can be in wait state
return;
}
}
}