Saving events to Events DB : Fixed bugs when connection string was not defined.
This commit is contained in:
@@ -286,7 +286,7 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
|
||||
opCompleted = true;
|
||||
if (SaveTracingRecords(batch) != Retv.OK) anyError = true;
|
||||
|
||||
if (anyError)
|
||||
if (anyError && !string.IsNullOrEmpty(Events.DB.ConnectionString))
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -302,17 +302,13 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
|
||||
{
|
||||
log.ErrorFormat("Triggering event(s) failed: {0}", exc.Message);
|
||||
}
|
||||
}
|
||||
|
||||
return Event.ErrorProcessingResults;
|
||||
}
|
||||
else
|
||||
{
|
||||
return Event.ResultsWritten;
|
||||
}
|
||||
return anyError ? Event.ErrorProcessingResults : Event.ResultsWritten;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (anyError)
|
||||
if (anyError && !string.IsNullOrEmpty(Events.DB.ConnectionString))
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -328,13 +324,9 @@ namespace TBF.BenchControl.Output.DB.ProductionTracing
|
||||
{
|
||||
log.ErrorFormat("Triggering event(s) failed: {0}", exc.Message);
|
||||
}
|
||||
}
|
||||
|
||||
return Event.ErrorProcessingResults;
|
||||
}
|
||||
else
|
||||
{
|
||||
return Event.ResultsWritten;
|
||||
}
|
||||
return anyError ? Event.ErrorProcessingResults : Event.ResultsWritten;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user