• Intermediate - Advanced - C# - Software Engineering

    Advanced C# Tips: Using Array Segments Instead of Copying Arrays

    Even though it is not a very popular C# tool, the ArraySegment<T> is quite old and it was introduced in .NET Framework 2.0, which was released in 2005. It is available for developers to utilize in their applications to improve performance when dealing with partial arrays. Technically, an ArraySegment is a struct, in other words, it is a value type in C#. When you instantiate an ArraySegment<T>, you are creating a lightweight object that doesn’t have the overhead of a class, such as a reference type’s heap allocation etc. The ArraySegment<T> struct internally holds three pieces of data: a reference…

  • Intermediate - Advanced - Coding - C# - Software Engineering

    Advanced C# Tips: Reuse Objects Where Possible

    Reusing objects in C# is a strategy that aligns with the principles of efficient memory management and application performance optimization. This concept is important in environments where memory resources are limited or when the cost of object creation is high. For instance mobile applications, embedded systems, or server applications handling multiple concurrent requests count as typical examples. The underlying technical reason for object reuse is to reduce the overhead related to the memory allocation and garbage collection. Every time an object is created, the .NET runtime needs to allocate space on the managed heap. As objects accumulate, the garbage collector…

  • Intermediate - Web Development - Java - Azure - C# - React

    Azure Active Directory Login with React, with C# or Java Backend

    Keeping things secure is the important part of any application. As entire internet going to cloud, Azure Active Directory (AD) is one of the best possible among one of two popular options. It helps manage who can use your app and what they can do. Let’s see how to set up Azure AD for a C# and Java Spring Boot backend, and a React frontend to make sure only the right people get in. First, go to the Azure portal and make a new Azure AD tenant if you don’t have one yet. Then, register your app in Azure AD.…

  • Coding - Beginner - Intermediate

    Architectural Design Patterns 9 – Circuit Breaker

    When designing systems, especially distributed systems, the flow of data and service requests must remain continuous. This brings us to an architectural design pattern called the Circuit Breaker. It comes from electronics. Simply, it is designed to stop the flow when something goes wrong. This prevents potential cascading failures in a system. Understanding the Circuit Breaker Pattern Imagine a scenario where a service relies heavily on another third-party service. However, that third-party service becomes slow or starts to fail at some point. Without any preventive measures, our service will keep making requests, waiting for timeouts, even getting stuck. This is…

  • Beginner - Intermediate - Coding - Web Development

    PHP: The All Times Survivor

    Whenever a major improvement happens in web technology, whenever a new framework or a language is introduced in the web development market, PHP’s death is declared immediately. I have been witnessing a recent popular belief that PHP is nearing its end due to NodeJS becoming the new “darling” of the developer community. To me, this belief is a naive statement comes from lack of knowledge on the history of programming languages since the story of PHP is the greatest survival story of the entire computer science history. Over the years, many people have declared the death of PHP against a…

  • Web Development - Beginner - Intermediate - Angular - React

    React vs. Angular: Choosing the Right Framework in 2024

    “Angular or React?” has been one of the most important questions in software development for the last decade. As a developer who had worked in full-stack fashion for a long time myself, my story of frontend started with Angular but had slightly moved towards React. Since I have actively participated projects in both, I wanted to write a comprehensive comparison between these two. Let’s explore the key aspects of each framework to help you make a decision, if you need to. Brief Overview: Developed and maintained by Facebook, React is a component-based library that deals mainly with the view layer…

  • Cloud Computing - Intermediate - Coding - Python - NoSQL - C#

    Remote Caching in Scaled-Out Cloud Applications: A Case Study with Redis, C# and Python

    A few weeks ago, we were discussing a problem with my team mates and a colleague raised a question about a very basic distributed remote caching problem which was about an application scaled out across multiple instances, managing how data is cached can become a significant challenge. Let me take the shortcut and directly jump into the problem. Consider a scenario where you have multiple instances doing the same job and you need to cache the result of a function which takes about 30 seconds. This function’s result needs to be cached to avoid redundant executions across different instances. The…

  • Web Development - Intermediate - Advanced - Coding - Angular

    Using SignalR with Angular

    In a previous blog post, we discussed how to create real-time web applications using SignalR and React. If you have already gone through that, you would know the magic of SignalR in pushing instant updates, allowing users to receive data in real-time. In this post, we’re going to apply the same concept but with Angular. Setting Up the Server with SignalR Just as a quick refresher, SignalR provides an easy method to communicate between the server and the client in real-time. We start by installing the appropriate NuGet package: The hub, as described before, acts as the communication centre. Here’s…

  • Intermediate - Coding

    Architectural Design Patterns 8 – Serverless (Function as a Service – FaaS)

    Today’s topic is a quite popular one, a fuzzy word getting more and more popular once it used to be a niche architectural pattern only. When we think about building software, a lot of the time and energy is spent thinking about where and how it will run. Serverless architecture, also known as Function as a Service or FaaS, helps this to change. Instead of planning the environment to run, developers mainly write functions and let cloud providers like AWS or Azure handle where it runs. Briefly describing, Serverless is an architectural model where cloud providers fully manage code execution.…

  • C# - React - Web Development - Intermediate - Coding

    Using SignalR with React

    Recently, I had the opportunity to work on a project where React and SignalR were integrated. This experience was quite insightful, and I am eager to share my learnings about this effective combination. SignalR is a library provided by Microsoft, designed to add real-time functionality to web applications. This means that applications can automatically push content to connected clients without them requesting it. Imagine a chat app where messages pop up instantly, or a stock monitoring tool where data refreshes in real time SignalR would be a good choice. Combining SignalR with React offers a dynamic platform for real-time web…

  • Intermediate - Coding

    Architectural Design Patterns 7 – Domain-Driven Design

    Domain-Driven Design, or DDD for short, isn’t about code at first. It’s about understanding the main business inside out, and then designing software that speaks the business’s language. Think about a hospital system. Before we write code, we would talk about patients, doctors, treatments, and appointments. By diving deep into the “domain” or the core of the business, we create software that feels like it was tailor-made for it. DDD is super useful for businesses with unique rules and ways of doing things. Let’s take insurance as an example. They’ve got tons of rules on who gets covered, how much…

  • Coding - Intermediate

    Architectural Design Patterns 6 – Service-Oriented Architecture

    Service-Oriented Architecture, often known simply as SOA, can be thought of as a city of services. In this city, each service is like a shop. Every shop provides a unique product or service but doesn’t worry about the other shops around it. Instead, it focuses on doing its own job really well. So, SOA is about creating independent services that work together in a large system. Now, where would you find SOA being used? Imagine big companies with different departments, like finance, human resources, or sales. Each department uses different software. With SOA, these different pieces of software can communicate…

  • Coding - Angular - Web Development - Intermediate

    Two-Way Data Binding in Angular: Its Pros and Cons

    Two-way data binding is one of the most distinctive features of Angular but what does it require, and what are the benefits and drawbacks associated with it? Let’s dive into it. When you hear “two-way data binding”, picture a bridge with traffic flowing in both directions. In an Angular application, this means that any changes to the model are instantly reflected in the view and vice versa. This can be a game-changer as it reduces the amount of boilerplate code developers have to write to maintain synchronization between the UI and data. For instance, consider a simple example where we…

  • Beginner - Intermediate - React

    NextJS: Frontend Sneaking into Backend

    As web-based applications become more sophisticated, frontend and backend lines gets blur. One such example of this change is NextJS. NextJS is a framework that enables React applications to render on the server side. But it isn’t just that. It pushes React into territories that it wasn’t initially designed for, filling in gaps and streamlining the development process. React and NextJS – A Beautiful TangoReact, as many know, is a JavaScript library built to create user interfaces. It does this primarily on the client side. While it’s incredible at this, it left a void when it comes to server-side rendering.…

  • Intermediate - Coding

    Architectural Design Patterns 5 – Monolithic

    I am aware that in our present day world, it is a sin to talk about monolith and not to curse it. However, I am will neither hallelujah nor curse it. I will just try to explain it as an architectural design pattern and try to expose both positive and negative sides of it. The Monolithic architecture stands as a testament to the earlier days of software development. A monolithic architecture is like a single, tightly packed unit where all the software components are bundled together. Think of it as a large factory where every product stage, from raw materials…

  • Intermediate - Coding - React - Web Development - Beginner

    Redux vs. useContext: Navigating the State Management Maze

    Every developer knows that the software engineering isn’t just about writing code. It’s about creating efficient, maintainable, and scalable systems. A critical part of that journey, especially in React, is the state management. With numerous tools and libraries available, the choices can often be way too much. Two most common players in this arena are Redux and useContext hook which is native to React. Both offer ways to manage global state, but which is right for your project? Let’s dive in and understand these tools better. Understanding useContext HookAt its heart, useContext is a React hook introduced in version 16.8…