Exemplo n.º 1
0
 public static async Task Handle(
     ItemCreated created,
     NpgsqlTransaction tx, // the current transaction
     Envelope envelope)
 {
     // Using some extension method helpers inside of Jasper here
     await tx.CreateCommand("insert into receiver.item_created (id, name) values (@id, @name)")
     .With("id", created.Id)
     .With("name", created.Name)
     .ExecuteNonQueryAsync();
 }