Insights and perspectives to keep you updated.

Using Spark as a Database

Reading Time: 4 minutes You must have heard that Apache Spark is a powerful distributed data processing engine. But do you know that Spark (with the help of Hive) can also act as a database? So, in this blog, we will learn how Apache Spark can be leveraged as a database by creating tables in it and querying upon them. Introduction Since Spark is a database in itself, we Continue Reading

New Chaining Operations in Scala 2.13

Reading Time: 2 minutes Scala 2.13 gave us two chaining operations, namely pipe and tap. To call methods one after the other in one go, we use chaining operations. Pipe pipe() is used to convert the input value to a new output value formed by applying the function provided to it in the parameter.Definition : def pipe[B](f: (A) => B) : BHere, the input value of type A will be converted Continue Reading

Either in Cats vs Either in Scala

Reading Time: 4 minutes Hola amigos! Last time I discussed Monads in general and in Cats as well. In this blog, let’s have a look at one of the most known monad Either. I’ll be giving an introduction to it and also there will be a comparison between two i.e Either in Cats vs Either in Scala. What is Either? Either basically represents a value of one of two Continue Reading

Diving into Scala Cats – Semigroups

Reading Time: 2 minutes New to Cats? No worries, go through my previous article Getting Started with Scala Cats to understand how amazing Cats is. In this article, we will cover the concepts and implementation of Semigroups in Cats. What are Semigroups? In functional programming terms a Semigroup is a concept which encapsulates aggregation with an associative binary operation. The Semigroup type class comes with a method combine which simply combines Continue Reading

Using the Gradle Checkstyle and PMD Plugins

Reading Time: 2 minutes Checkstyle is a library that analyzes a java project source code against a set of style rules to ensure that all contributions to a project adhere to a certain standard. This improves the readability of the code, decreases the time required to onboard new team members and improves the maintainability of the source code. PMD is a library that analyzes a java project source code Continue Reading

An Introduction to Mako Templates in Python

Reading Time: 3 minutes Introduction to Mako Have you ever worked on a project in Python and thought to yourself, “Gee, it would be nice if I could dynamically generate web pages and/or text and have them directly interact with my program.” Well, you’re in luck because enter Mako templates. Mako is a template library and a Python Sever Page language, allowing content such as HTML, XML, and text Continue Reading

Marshmallow: Easy Serialization in Python

Reading Time: 2 minutes Introduction Marshmallow, stylized as “marshmallow”, is an object-relational mapping library which is used to convert objects to and from Python data types. It is often used alongside SQLAlchemy, an ORM that maps database schemas to Python objects. Marshmallow is often used to deserialize Python dicts to SQLAlchemy models and vice versa. Let’s focus on how to use Marshmallow. Creating Schemas First, we need to create Continue Reading

Unit testing void methods with Mockito and JUnit

Reading Time: 3 minutes Writing functionality is the main focus whenever we are writing a software program, but it is equally important that we make sure our code works the way we intended it to. And how do we do that? By writing unit test cases. They are used to test the smallest functionality of code. Unit test cases are an essential part of software development. In this blog, Continue Reading

What Are Docker Containers And Why Use Them

Reading Time: 2 minutes In this blog I’ll talk briefly about Docker. People usually compare it to virtual machines, which is not really a fair comparison. Virtual machines are used to solve the problem of compatibility, for example if your code runs on your machine but doesn’t run on another developer’s machine because you’re basically working on a different environment. Docker however runs as a container and sits on Continue Reading