mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 03:25:23 +08:00
Added batch label to log messages.
This commit is contained in:
@@ -118,12 +118,12 @@ namespace Orchard.Recipes.Providers.Executors {
|
|||||||
if (elementDictionary[nextIdentityValue].HasAttributes) {
|
if (elementDictionary[nextIdentityValue].HasAttributes) {
|
||||||
itemId = elementDictionary[nextIdentityValue].FirstAttribute.Value;
|
itemId = elementDictionary[nextIdentityValue].FirstAttribute.Value;
|
||||||
}
|
}
|
||||||
Logger.Information("Handling content item '{0}' (item {1}/{2}).", itemId, itemIndex + 1, elementDictionary.Count);
|
Logger.Information("Handling content item '{0}' (item {1}/{2} of '{3}').", itemId, itemIndex + 1, elementDictionary.Count, batchLabel);
|
||||||
try {
|
try {
|
||||||
contentItemAction(itemId, nextIdentityValue, elementDictionary[nextIdentityValue], importContentSession, elementDictionary);
|
contentItemAction(itemId, nextIdentityValue, elementDictionary[nextIdentityValue], importContentSession, elementDictionary);
|
||||||
}
|
}
|
||||||
catch (Exception ex) {
|
catch (Exception ex) {
|
||||||
Logger.Error(ex, "Error while handling content item '{0}'.", itemId);
|
Logger.Error(ex, "Error while handling content item '{0}' (item {1}/{2} of '{3}').", itemId, itemIndex + 1, elementDictionary.Count, batchLabel);
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
itemIndex++;
|
itemIndex++;
|
||||||
|
Reference in New Issue
Block a user