public async Task <IUserQueue> Update(IUserQueue entity) { TUserQueue tEntity = entity as TUserQueue; var errors = await this.ValidateEntityToCheckExistsAtUpdate(tEntity); if (errors.Count() > 0) { await this.ThrowEntityException(errors); } try { this.StartTransaction(); await base.Update(tEntity, x => new { x.UserId, x.QueueId }); this.CommitTransaction(); return(tEntity); } catch (PostgresException ex) { throw new EntityUpdateException(ex); } catch { throw; } }
public QueueLogic(IUserQueue userQueue, ILogger <QueueLogic> logger, IMessageQueueHelperFactory messageQueueHelperFactory) { _userQueue = userQueue; _logger = logger; _messageQueueHelperFactory = messageQueueHelperFactory; }
public MessagesController(IUserQueue usersQueue, IMessageQueue messegesQueue) { _usersQueue = usersQueue; _messegesQueue = messegesQueue; }
public void TestInitialize() { queue = new UserQueue <int>(); }
public QueueController(IUserQueue userQueue) =>