Immutable Dtos #142
-
Hi, What do you think about make Dtos fetched by dapper immutable? Like this: |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hi, @kamilbaczek! On the other hand Read Model can be used to provide data to Write Model (instead of loading aggregates). Performance is the main reason for this approach. For example |
Beta Was this translation helpful? Give feedback.
-
Hi @kamilbaczek We can do that but from what I remember you need to have a constructor with parameters in a special order. If you have different order you will have a runtime error during deserialization. Maybe something changed since I had checked this. I will check. |
Beta Was this translation helpful? Give feedback.
Hi @kamilbaczek
We can do that but from what I remember you need to have a constructor with parameters in a special order. If you have different order you will have a runtime error during deserialization. Maybe something changed since I had checked this. I will check.