public async Task ProcessAsync(ProcessStepViewModel model) { var stepper = await this.Find(model.Id); await this.jobQueueService.Enqueue(WorkItem.Create( model.Trigger, stepper.Id, stepper.Type )); }
public async Task ProcessAsync(ProcessStepViewModel model) { var stepper = await this.Find(model.Id); await _messageBus.PublishAsync(WorkItemMessage.Create( model.Trigger, stepper.Id, stepper.Type )); }
public async Task Process([FromBody] ProcessStepViewModel model) { if (model == null) { BadRequest(); } if (!this.ModelState.IsValid) { BadRequest(this.ModelState); } await this._service.ProcessAsync(model); Ok(); }