Implement and publish a Worker Service in .Net Core 3


With the release of Net Core 3. The Asp.Net team introduced a new template for building background applications called Worker Service, which is available as part of the SDK. Worker Services are designed to do background work, and the main feature of ....
Read more

Accurate tagging of queries in the Entity Framework Core


Sometimes we may write queries in the EF and retrieve a lot of data from the database, and as the project gets bigger, the number of queries increases, making it difficult or impossible to find heavy queries. If you get these queries in SQL Profiler, it is almost impossible to find a written query ....
Read more

Invalid cookies after changing users' passwords


In Asp.Net Core, cookies are validated every 30 minutes by default. This means that when the user logs in to the site and enters their information, the user's current claims are stored in the cookie and can access the pages they want, and the cookies are not validated for up to 30 minutes, eve ....
Read more

A way to restrict APIs that each request can be called with a new key (Time-based One-time Password)


TOTP is an algorithm that uses clocks to generate one-time passwords. In this way, a unique code will be generated at any moment. If you have worked with Google Authenticator, you are familiar with this concept. In this article, we want to implement a scenario in which APIs must send a ....
Read more

بدست آوردن دیتاهای سلسله مراتبی در SQL


ساختار نظرات یک پست را در نظر بگیرید. هر شخصی میتواند برای هر پستی نظر بگذارد و هرشخص میتواند برای نظر دیگری یک نظر جدید وارد کند. نظرات به صورت پدر و فرزندی میباشد یعنی هر نظر میتواند چندین فرزند داشته باشد ولی هر نظر فقط یک پدر دارد و در نهایت میخواهید کل نظرات ثبت شده برای یک نظر خاص ....
Read more