ASP.NET Core WebAPI Payload Logging with Serilog

Problem Statement Imagine debugging a tricky API integration where you’re getting intermittent errors. You suspect the data being sent is the culprit, but you’re flying blind. Wouldn’t it be great if you could see exactly what’s going over the wire?. For some API-based applications, logging the payload for a given transaction is helpful from both audit and monitoring perspectives. While it’s generally not recommended to log the request or response body due to performance/compliance/security considerations, if there is a need for such a requirement and you understand all the risks, then hopefully this guide provides one of the many ways to achieve it....

February 23, 2025 · 6 min · Imran

Python SonarQube Code Coverage & Quality

In this article, we will look at how to run pylint, bandit, pytest and coverage utilities to generate and upload code coverage, quality reports to SonarQube server. Required Software Docker: To run SonarQube and SonarQube CLI containers. Python3 pip3: To install required dependencies. Python3.x-venv: Optional but recommended. SonarQube Setup Run following commands to bring SonarQube Docker. Let’s create docker network first so our Sonar CLI container can interact with SonarQube Server....

November 28, 2024 · 2 min · Imran

AWS ECS Deployments with Helm Templates

Typically, helm is used for creating deployment charts for kubernetes platform but I like the helm templating features to generate YAML specifications which can be used to deploy to any platform. AWS Elastic Container Service(ECS) is another platform where you can run container workloads in AWS Cloud. While I won’t go deep into AWS ECS platform or setting up cluster in this article, we will quickly look at how we can deploy a service to an existing ECS cluster with Helm Templates and AWS CLI....

August 10, 2024 · 4 min · Imran