Extending functionality using Decorator Pattern (C#)

Introduction The decorator pattern is a structural design pattern which allows you to dynamically add functionality to classes without modifying the target class. It does this by creating a wrapper around the original class, which gives you an extension point to inject in new behavior. It allows you to maintain a strong separation of concerns … Read more

Build a simple Chat Room using Mediator Pattern (C#)

Introduction I’ve previously written about Mediator pattern and how it encapsulates object’s interaction and communication. This pattern promotes loose coupling between software components. It acts as a communication hub and it facilitates one-to-many, many-to-one and many-to-many communications. We than saw an example of Vehicles Control Center where vehicles position is communicated to control center. We … Read more

Working with XML Using C#

Introduction The Extensible Markup Language (XML) is a simple text-based format for representing structured information: documents, data, configuration, books, transactions, invoices, and much more. It is a very common format and In this post, we will learn some of the basic ways to work with XML in C#. Getting Started XDocument and XElement are the … Read more

Kubernetes Storage – Dynamic Provisioning using Storage Classes

Introduction In previous post, we learned that Kubernetes Persistent Volume Subsystem decouples data from application pods and containers and abstracts implementation details. The main components are as follows: PersistentVolume (expose external storage to a PV) PersistentVolumeClaim (a request for persistent volume) StorageClasses (for dynamic provisioning) We then used PersistentVolume and PersistentVolumeClaim in a static provisioning … Read more

Create PDF documents using Node.js (PDFKit)

Introduction Creating PDF files is a very common requirement in many software applications. In this post we will see how to easily create PDF documents using Nodejs. So instead of building all PDF files related functionality ourselves, there is node package called PDFKit, that abstracts all this complexity and give us a nice API to … Read more

Persistent Volumes in Kubernetes

Introduction In this post, we will learn how persistence storage objects in kubernetes provide an easy way to meet storage requirements of statefull applications. In previous post, we learned how to use volume plugins for external storage and we used an AWS EBS volume for this purpose. However, we used AWS EBS volume settings directly … Read more