ConcurentDictionary has one specific feature: in some cases it may not behave exactly as you'd expect. Here is a small example.
Eyes wide open - Correct Caching is always hardIn my last post I talked about Caching and some of the stuff I've been doing to cache the results of a VERY expensive call to the backend that hosts my podcast. As always, the comments are better than the post! Thanks to you, Dear Reader.
Making ConcurrentDictionary GetOrAdd thread safe using LazyI was browsing the ASP.NET Core MVC GitHub repo the other day, checking out the new 1.1.0 Preview 1 code, when I spotted a usage of ConcurrentDictionary that I thought was interesting.
Dependency Injection revisited - Mark SeemannOver the last decade, Dependency Injection has moved from obscurity into the realm of something that every library and framework must address. During the same time, functional programming has gathered much interest. Dependency Injection is an attempt to control non-deterministic behaviour, but the w
Mod and Remainder are not the SameGet ready, here comes some fringe pedantry that could very well be the difference in an interview, or the thing that saves you from hours of chasing a production bug!
Task, Async Await, ValueTask, IValueTaskSource and how to keep your sanity in modern .NET worldC# and .NET went through a lot of changes in recent years. First, came Task Parallel Library. Later, async-await made everyone adding Async suffix to their methods and putting a lot of awaits.
Cost of a JoinHow expensive is a join?
[EN] How does Two-Factor Authentication - 2FA work?We often hear that if a website supports two-factor authentication, it is worth to enable it for our account. That’s what security people use to say. But how does it work? Why does it increase the security of our account so much? Today's episode is all about it.I will outline how the "Time-based O
SOLID Principles Around YouIn this article I want to briefly go through SOLID principles (acronym that stands for five basic principles of object-oriented programming and design) supplying each of them with real-world visual examples to make those principles more understandable, readable and memorizable.
In MySQL, never use “utf8”. Use “utf8mb4”.This is a UTF-8 client and a UTF-8 server, in a UTF-8 database with a UTF-8 collation. The string, “? <…”, is valid UTF-8. But here’s the rub: MySQL’s “utf8” isn’t UTF-8.
This Read-It-Later-list is just that, bookmarks of stuff I intend to read or have read. I do not necessarily agree with opinions or statements in the bookmarked articles.
This list is compiled from my Pocket list.