Building Secure ASP.NET MVC Web Applications

Introduction Building secure distributed Web applications is challenging. There’s nothing more exciting than creating a fancy web application. What isn’t as exciting, however, is the security risk involved. When it comes to web application development in today’s increasingly digitized, mobilized, Internet-of-Things world, security measures can no longer be the afterthoughts they once were. With distributed applications, you have a lot […]

Writing Testable & Clean Code

Many developers have a hate relationship with testing. However, I believe the main cause of that is code that is highly-coupled and difficult to test. This post states some principles and guidelines that can help you write easily-testable code, which is not only easier to test but also more flexible and maintainable, due to its better modularity. Here […]

C# Performance Tips

Check List has items List.Count() vs List.Any() Stopwatch watch = new Stopwatch(); List < string > strs = new List < string > () { “Akshay”, “Patel”, “Panth”, “Patel” }; watch.Start(); if (strs.Count() > 0) {} Console.WriteLine(“List.Count()-{0}”, watch.Elapsed); ——– watch.Restart(); if (strs.Any()) {} Console.WriteLine(“List.Any() – {0}”, watch.Elapsed);   Loop on items in a list Array.Length vs var i […]

Entity Signal – Real Time Entity Framework (EF) and ASP.NET core

What is Entity Signal? Entity Signal allows you to connect to Entity Framework through SignalR and get updates on subscribed data in real time. This lowers the number of refreshes done by the user and ultimately allows you to do more with fewer servers. It is also requires minimal changes, so you can make realtime apps about as […]