Dependency Injection in the ASP.NET Core Middleware

Dependency Injection in the ASP.NET Core Middleware

I am creating a project called Stactive, which will be helpful in logging requests and other events from the ASP.NET Core applications. Today, I introduced a RequestLogger class, which implements IRequestLogger interface. As always, I wanted to inject this in the constructor and realised it needs to be registered in the DI container. I would like to show you how it’s done.

read more

Angular - wait for a resource to load

Angular - wait for a resource to load

I have recently faced an interesting issue in an Angular application. It was an e-commerce solution, where a user could change his currency. I was using a modified price pipe, which had a dependency on settings containing the currency symbol. Because settings could be changed by a user, I had to get them from the server. The problem occurred when angular wanted to use the pipe before it loaded the settings. I had to make the app wait for settings before it rendered the page.

read more

Operating on time - why UTC

Operating on time - why UTC

Last weekend, we’ve had to adjust all of our watches in Europe to the Daylight Saving Time. On this occasion, we were moving an hour forward, which is not a big deal for IT systems. It’s much worse in October when you move back in time and have 2.30 two times during one night. I won’t be disputing if we should get rid of DST. Instead, I would like to show you how to deal with it in IT properly.

read more

Web Analytics