scala

Kalix.io – Platform-as-a-Service: Server less, Database less

Reading Time: 2 minutes Lightbend, comes with the new product that will meet the current developer problems and reduce the efforts while coding. Kalix.io comes with the advanced features that will compete the feature problems we face while developing Applications. Kalix combines the scalability and cost benefits of serverless infrastructure with the data management and responsiveness of stateful services. This adds up to one managed, cloud-based environment. By bringing Server, Continue Reading

What are Zio Effect Constructors?

Reading Time: 3 minutes In this blog post, we will discuss about ZIO effect constructors and how we can use them. Then we’ll take a look at Effect constructors for pure computations and side-effecting computations. Zio Effect Constructors A functional effect is a template for a concurrent workflow. The template which is mostly descriptive in nature, used to test for any side effects. Such as database interaction, logging, data Continue Reading

Experimenting with recursion and ZIO

Reading Time: 4 minutes If you’re already comfortable with recursion, you can skip the first part introducing tail-recursion and go directly to the ZIO section. Introduction: recursion and functional programming Recursion is one of the main techniques used in functional programming to replace an iterative loop. One of the most common examples is the Fibonacci computation or factorial computation. For this experiment, we will focus on an even simpler Continue Reading

zio

ZIO: The Most Important Data Type Of ZIO Library

Reading Time: 3 minutes Overview In this blog, we’ll understand about the most important data type of ZIO library i.e. ZIO and the type aliases available for it which are very useful when it comes to representing some common use cases. What is ZIO library used for? ZIO is a zero dependency Scala library that provides many features for developing concurrent, parallel, asynchronous and resources safe applications in a Continue Reading

Scala Higher Order Functions

Reading Time: 2 minutes Higher order function is a function that either takes a function as argument or returns a function. In other words we can say a function which works with function is called higher order function. Higher order function allows you to create function composition, lambda function or anonymous function etc. Let’s see an example. Passing a Function as Parameter in a Function Output: 50 Function Composition Continue Reading

Scala Traits in Simple words

Reading Time: 2 minutes In this blog post, we will talk about traits in Scala. Then we will discuss how is a trait different from abstract classes. Scala Traits A trait is similar to a partial implementation of an interface. A trait in Scala can contain abstract and non-abstract methods. We can make a trait with all abstract methods or some abstract methods and some non-abstract methods. Variables declared Continue Reading

File Handling and Operations in Scala

Reading Time: 3 minutes Today we will look into Scala File IO operations. So let’s start with the basic definition. File Handling is a way to store the fetched information in a file. File operations mainly include reading data from files or writing data into files. Here we will look into Scala read file and Scala write file programs. Creating and Writing to the file Scala doesn’t provide file writing Continue Reading

All you need to know about SOLID Principles

Reading Time: 3 minutes In this blog post, we will discuss about SOLID principles in Scala which are the 5 most recommended design principles. What are SOLID Principles ? The abbreviation SOLID stands for a collection of principles that, when combined, make code more adaptable to change. SOLID principles assist us in making our software more readable, understandable, flexible. They serve as the foundation for developing object-oriented applications that Continue Reading

What is Pure Function | Functional Programming in Scala

Reading Time: 2 minutes What is Functional Programming? Firstly, Functional programming is a programming paradigm in which everything is bound using pure mathematical functions. It’s a declarative programming approach. In contrast to an imperative style, which focuses on “how to solve,” it focuses on “what to solve.” Instead of statements, it uses expressions. A statement is executed to assign variables, but an expression is evaluated to create a value. Continue Reading

What are Case Classes in Scala

Reading Time: 2 minutes Case Classes in Scala Case classes in scala are regular classes with some extra toppings. Let’s discuss why they are high in demand. A case class with no arguments is declared as a case object rather than a case class. By default, the case object can be serialized. A Case Object is also like an object, which has more attributes than a regular Object and Case classes Continue Reading

How to deal with Option data type in Scala

Reading Time: 3 minutes In this blog post, we will talk about Option data type in Scala. Then we will discuss some of the methods for dealing with options. Options In Scala, an Option is a carrier of a single or no element for a specified type. An Option[T] object can be either Some[T] or None object, which represents a value that is not present. Thus, options mainly come Continue Reading

Apache Spark Streaming Checkpointing

Reading Time: 2 minutes Introduction The need of spark streaming application is that it should be running 24/7. Hence, it must be resilient to failures unrelated to application logic such as system failure, JVM crashes etc. The recovery should also be speedy in case of any loss of data. Spark streaming achieves this by the help of checkpointing. With the help of this, input DStreams can restore before failure Continue Reading

What Is RegEx? Its Importance and How To Use It.

Reading Time: 6 minutes In this blog, you will get a logical understanding of what is RegEx, what it can do, and what it can’t do, and also you will get a piece of knowledge about when to use them and — more importantly — when not to. So Let’s start. Introduction On an abstract level a regular expression, regex for short, is a shorthand representation for a set Continue Reading