public override Task <Empty> Setup(SetupRequest request, ServerCallContext context) { var loans = request.Loans.Select(l => mapper.Map <Repository.Loan>(l)); loansRepository.Setup(loans); return(Task.FromResult(new Empty())); }
public override Task <Empty> Setup(SetupRequest request, ServerCallContext context) { var loans = request.Loans.Select(l => mapper.Map <Models.Loan>(l)); loansRepository.Setup(loans); projectionChannel.Publish(null, new DataProjection <Models.Loan, string> { Upsert = loans.ToArray() }); return(Task.FromResult(new Empty())); }
public Task Setup(MessageContext context, SetupLoansEvent inputEvent) { loansRepository.Setup(inputEvent.Loans); return(Task.CompletedTask); }