Design

ScalaFP: Mystery Of Scala Higher Kinded Type.

Reading Time: 3 minutes Scala type system holds a lot of mysteries. Sometimes these mysteries confuse us but mostly they provide us with a powerful feature. Today we will be discussing one of them called Higher Kinded Type Or Second Order Type. Before moving to higher kinded type lets brush up our basics first. Higher Order Function: So, functional programming follows an artistic rule called “functions are the first Continue Reading

Is Shifting to Domain Driven Design worth your Efforts?

Reading Time: 6 minutes In our earlier blog, we explored a bit about Microservices. But let’s take a step back and look into how microservices can be effectively designed. Yes, you guessed it right. We will be talking about the Domain Driven Design or what we call the DDD approach. But before jumping into the concepts of Domain Driven Design, let’s understand 2 basic terminologies : Domain: A domain is the sphere Continue Reading

Terraform: Enabling developer to create and manage deployment through code

Reading Time: 2 minutes In this blog post, We will walk you through Terraform which is a tool for building, changing, and versioning infrastructure safely and efficiently. Terraform enables the developers to properly manage the infrastructure through code. The set of files used to describe infrastructure in Terraform is simply known as a Terraform configuration. These files have extension .tf. Configuration files describe to Terraform the components needed to Continue Reading

Scala Best Practices : Pure Functions

Reading Time: 5 minutes We grew up in a world of imperative programming that’s why we are more addictive to writing code in imperative style. Everything is mutable around us. Mutability is not that bad. But shared mutability is devil’s work. The moment we bring shared mutability all kinds of problem creep in. Functional Style has a way to handle this. Functional programming is a way of writing software Continue Reading

Partial Functions and Modularizing Actor Receive blocks

Reading Time: 2 minutes A partial function is defined as trait PartialFunction[-A, +B] extends (A) ⇒ B It is a unary function which defines a domain. Not all values of A would be a part of the domain. For instance, in the following code block val sample = 1 to 10 val isEven: PartialFunction[Int, String] = { case x if x % 2 == 0 => x+" is even" Continue Reading