public async Task UpdateAsync(UniqueStoreUpdateItem item, CancellationToken cancel)
        {
            using (var db = await _db.CreateAsync(cancel).ConfigureFalse())
            {
                using (var t = db.BeginTransaction())
                {
                    if (await db.IsDuplicateOperationAsync(item.ToIdempotencyId(), cancel))
                    {
                        return;
                    }

                    try
                    {
                        item.Changes.ForEach(d =>
                        {
                            db.Update <UniqueStoreRow>()
                            .Set(r => r.Value, UniqueStoreRow.Pack(d.Value))
                            .Where(r => r.EntityId == item.EntityId && r.Aspect == UniqueStoreRow.Pack(d.Aspect))
                            .Execute();
                        });
                        t.Commit();
                    }
                    catch (DbException ex) when(db.IsUniqueViolation(ex))
                    {
                        throw new UniqueStoreDuplicateException(ex.Message);
                    }
                }
            }
        }
 public async Task DeleteAsync(string bucketId, CancellationToken cancel)
 {
     using (var db = await _db.CreateAsync(cancel).ConfigureFalse())
     {
         await db.DeleteFromAsync <UniqueStoreRow>(cancel, d => d.Bucket == UniqueStoreRow.Pack(bucketId)).ConfigureFalse();
     }
 }
 public async Task DeleteAsync(UniqueStoreDeleteItem item, CancellationToken cancel)
 {
     using (var db = await _db.CreateAsync(cancel).ConfigureFalse())
     {
         await db.DeleteFromAsync <UniqueStoreRow>(cancel, d => d.EntityId == item.EntityId && d.Aspect == UniqueStoreRow.Pack(item.Aspect)).ConfigureFalse();
     }
 }