Skip to content

Commit

Permalink
Merge branch 'hotfix-8.1.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
SzymonPobiega committed Aug 29, 2018
2 parents d3c6221 + 1fb56f5 commit 4abc90b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/NServiceBus.NHibernate/Deduplication/GatewayDeduplication.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,21 @@ await session.SaveAsync(gatewayMessage)
await tx.CommitAsync()
.ConfigureAwait(false);
}
catch (GenericADOException)
catch (ConstraintViolationException)
{
await tx.RollbackAsync()
.ConfigureAwait(false);
return false;
}
catch (ADOException)
{
await tx.RollbackAsync()
.ConfigureAwait(false);
throw;
}
}

return true;
}
}
}
}

0 comments on commit 4abc90b

Please sign in to comment.