Hi All,
our scenario : we do the following in our handler
- SaveAnOrder()
–>This calls a facade
→ the domain facade calls a sql helper class which uses Dapper ORM to
save the order to the db - Finally raise an “OrderCreated” Event
Questions
-
From what I have read about the Outbox pattern, the same transaction and connection should be used between the dapper ORM and Outbox, if this the case, what are my options to enable outbox here
a) should i send the context context.SynchronizedStorageSession.MyPersistenceSession(), to my
the façade layer which will in turn send it into the SQL Dapper class and use the connection and
transaction object?the problem with the above approach is that
- my façade class and ORM class is taking a dependency on the NserviceBus,
- assuming even if were to convince everybody, how are we going to mock the the
context.SynchronizedStorageSession.MyPersistenceSession() in unit tests. - And how do we pass this dependency during my ORM integration tests ?
-
Can we use ASB transport along with SQL persistence outbox ? or does it have to SQL transport
and SQL persistence ? -
Does SQLPersistence support Azure Managed Identity ?
-
Can we dispose the connection and transaction (using statement) that we get from the context.SynchronizedStorageSession.MyPersistenceSession() ?, basically dapper methods are extension methods on the connection object ?
-
I could only find EntityFramework ORM examples, any pointers on how we can accomplish the same thing with dapper ? any example would be really helpful.
Thanks -Nen