Closed jmalloc closed 6 years ago
Merging #78 into master will increase coverage by
0.37%
. The diff coverage is0%
.
@@ Coverage Diff @@
## master #78 +/- ##
==========================================
+ Coverage 33.87% 34.25% +0.37%
==========================================
Files 54 53 -1
Lines 1898 1877 -21
==========================================
Hits 643 643
+ Misses 1245 1224 -21
Partials 10 10
Impacted Files | Coverage Δ | |
---|---|---|
src/axmysql/keyset.go | 0% <0%> (ø) |
|
src/ax/saga/behavior.go | 0% <0%> (ø) |
:arrow_up: |
src/ax/saga/handler.go | 0% <0%> (ø) |
:arrow_up: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 214223e...49afe37. Read the comment docs.
"Key set" based mapping was previously the only strategy available. But, for aggregates at least, it will be the common case that a message contains the instance ID as one of its fields. In this case we can use a simpler strategy that obtains the instance ID directly from the message.
This PR opens the door to such a strategy by removing the keyset based mapping logic from
saga.Handler
and moving it into an implementation ofsaga.Mapper
, which has been repurposed from what is now known askeyset.Repository
to a more generic interface for any kind of mapping logic.