Sunday, June 26

What Microsoft’s Scott Hanselman Does Not Tell You About His Work

 

Source: What Microsoft’s Scott Hanselman Does Not Tell You About His Work

Discovered on: 2021-10-30 21:37:04


Scott Hanselman of Microsoft won’t tell you that his Contoso Crafts demo will break if forced to process a large amount of data. This means that new developers are likely to get suckered into using ASP.net Core thinking it will be easy because of how easy he makes it look in his demo. Then they will copy his methods as close as possible thinking that surely a Microsoft employee would lead them down the right path. Everything will seem fine for awhile until they have a lot of data in their posts table at which point the dataset is too big to work with Scott’s get all data method. Don’t believe me? Just look at how slow this site is and how often error messages are displayed instead of posts.

Other developers are recommending the use of something called a ViewModel which Hanselman never discussed in Contoso Crafts. They say using the ViewModel to compute properties would be preferable to doing it the GetPosts() method of the PostsService class. I thought everything needed to be computed in a service class since that is how it was done in Contoso Crafts and other examples from either Microsoft or other so called ASP.Net experts.

Leave a Reply

Your email address will not be published.