no dogma blog
no dogma blog
Blog Posts
Podcast
Web API Lambda Course
Polly Course
Photos
Contact
Support this Site
About
RSS
Light
Dark
Automatic
Posts
Passing Configuration Options Into Middleware, Services and Controllers in ASP.NET Core 3.1
Full source code here. I recently hit a problem where I needed to reload configuration settings as they changed, fortunately, this is relatively straightforward when using the IOptionsMonitor, in .NET Core.
Dec 1, 2019
#
dotNet Core 3.1
,
AspNet
,
Dependency Injection
,
IOptionsMonitor
,
Middleware
,
Options
,
WebApi
Simmy Chaos Engine for .NET – Part 5, Breaking Your Own Code
Full source code here. Want to learn more about Polly? Check out my Pluralsight course on it. The blog posts I have written so far about Simmy all deal with the scenario where you don’t have control over the source code that you want to break, in these cases Simmy policies are applied to the calling code.
Nov 12, 2019
#
AspNet
,
Chaos Engineering
,
Polly
,
Simmy
,
WebApi Core
,
WebApi
Registering Multiple Implementations of an Interface in ASP.NET Core with Autofac
Full source code here. A few weeks ago I wrote a post about using dependency injection to pick between two implementations of an interface. It was a solution I was not very happy with because it meant I had to new up the implementations inside a factory or I had to use service collection to instantiate all implementations of the interface and then use a piece of code to return the one the was wanted.
Oct 27, 2019
#
dotNet Core
,
AspNet
,
Autofac
,
Dependency Injection
,
ServiceCollection
,
WebApi
Simmy Chaos Engine for .NET – Part 4, Doing Some Real Damage, Dropping a Table
Full source code here. Want to learn more about Polly? Check out my Pluralsight course on it. Up until now the Simmy examples I’ve written have thrown exceptions, changed successes to failures or slowed down a request.
Oct 14, 2019
#
dotNet
,
AspNet
,
Chaos Engineering
,
Polly
,
Simmy
,
WebApi
Registering Multiple Implementations of an Interface with Service Collection in ASP.NET Core
Full source code here. This is a simplistic approach to the problem and assumes that the dependencies created by the factory do not in turn have their own dependencies. This deficiency could be mediated by passing those dependencies into the factory.
Oct 1, 2019
#
dotNet
,
AspNet
,
Dependency Injection
,
HttpContext
,
ServiceCollection
,
WebApi
Accessing the HttpContext from the Constructor of a Controller or a Dependency
Full source code here. There are times when you may need to access the HttpRequest from places that it is not normally available such as the constructor of a controller or the constructor of a service that is built by dependency injection.
Sep 15, 2019
#
dotNet
,
AspNet
,
Dependency Injection
,
HttpContext
,
WebApi
Simmy Chaos Engine for .NET – Part 3, Adding Latency
Full source code here. Want to learn more about Polly? Check out my Pluralsight course on it. This is the third in my series on chaos engineering with Simmy. The first two posts dealt with the fault policy throwing exceptions and returning failed responses rather than calling the remote service.
Aug 27, 2019
#
dotNet
,
AspNet
,
Chaos Engineering
,
Polly
,
Simmy
,
WebApi
Simmy Chaos Engine for .NET – Part 2, Resilience and Injected Faults
Full source code here. Want to learn more about Polly? Check out my Pluralsight course on it. I wrote a blog on using a Simmy Fault policy a few days ago, it is very simple to use by itself, but it is far more useful when used in combination with a resilience policy.
Jul 19, 2019
#
dotNet
,
AspNet
,
Chaos Engineering
,
Fault
,
Polly
,
Simmy
,
WebApi
Simmy Chaos Engine for .NET - Part 1, Injecting Faults
Full source code here. Want to learn more about Polly? Check out my Pluralsight course on it. For quite a while I have been writing, presenting and making videos about using Polly to make applications more stable.
Jul 11, 2019
#
dotNet
,
AspNet
,
Chaos Engineering
,
Fault
,
Polly
,
Simmy
,
WebApi
Streaming Results from Entity Framework Core and Web API Core
Full source code here. The code provided will not compile until you make a change in seeder.cs, the way it’s written it generates 500,000 rows in a local db. Set this to whatever value you want.
Jun 7, 2019
#
AspNet
,
Entity Framework Core
,
Streaming
,
WebApi Core
,
WebApi
«
»
Cite
×