public async Task ReplaceRoom(RoomsDB_RoomDTO update)
        {
            await _redisCache.Del($"Room:{update.Id}");

            _internalByIdCache.Remove(update.Id);
            _internalByDomainCache.Remove(update.Domain);
            await RoomWorker.ReplaceRoom(update);
        }
        public async Task ReplaceTest(TestsDB_TestDTO updatedTest)
        {
            await TestWorker.Replace(updatedTest);

            await _redisCache.Del($"Test:{updatedTest.Id}");
        }
 public async Task Del(Role role, ObjectId id, SecurityToken token)
 {
     JwtSecurityToken jwt = SecurityTokenConvertToJwtSecurityToken(token);
     await _cacheRepository.Del($"{role}:{id}:{jwt.EncodedPayload}");
 }
        public async Task <bool> SetProperty(ObjectId userId, string propertyName, object newPropertyValue)
        {
            await _redisCache.Del($"User:{userId}");

            return(await UserWorker.SetProperty(userId, propertyName, newPropertyValue));
        }
Esempio n. 5
0
        public async Task ReplaceMember(MembersDB_MemberDTO member)
        {
            await _redisCache.Del($"Member:{member.Id}");

            await Task.Run(() => MemberWorker.ReplaceMember(member));
        }