Refactored Code
Code Redesign
Finished Refactoring and Redesigning an entire software project. It took a few months, but it's now finally complete.


Our implementation was tightly coupled to an external system (IdentityServer4). We then wanted to support integration with another system (Duende IdentityServer). These two external systems are not compatible with each other and have different APIs. To support both of these systems within the same codebase whilst avoiding code replication, I did the following:

  • Implemented an Anti-Corruption Layer pattern to isolate our business logic from the code that interacts with external systems. The result was having a core library with our business logic and anti-corruption layers for interaction with external systems.
  • To isolate our business logic, I had to use design patterns such as Template, Adaptor, Strategy and Facade.

This redesign meant that we could stay in sync with the external systems whilst reducing the impact on our code when the external APIs change. This has also given us the option and ability to support other external systems in the future.