I had the exact same scenario as you. C# Lazy loaded props that read from db, serialization for redis = bad.
But I think that specific problem has more to do about what you are trying to cache. Ideally you would just cache a poco-model instead and use interfaces for your models. Then you don't need to worry about that at all.
That's what I did in my case, mostly because of constraints on changing the lazy-loading.
That said; lazy loading can cause all kinds of unexpected weird problems.
Cofounded Host Collective (DiscountASP.net). Cofounded Player Axis (Social Gaming). Computer Scientist and Technology Evangelist with 20+ years of experience with JavaScript!
I had the exact same scenario as you. C# Lazy loaded props that read from db, serialization for redis = bad.
But I think that specific problem has more to do about what you are trying to cache. Ideally you would just cache a poco-model instead and use interfaces for your models. Then you don't need to worry about that at all.
That's what I did in my case, mostly because of constraints on changing the lazy-loading.
That said; lazy loading can cause all kinds of unexpected weird problems.
The problem is so deep in the bones of the software, the company decided to just abandon the approach all together due to cost of repair.