Posts

Showing posts from March, 2025

API Testing Using Rest Assured: A Comprehensive Guide

API Testing Using Rest Assured: A Comprehensive Guide API Testing Using Rest Assured: A Comprehensive Guide Introduction In modern software development, APIs are at the heart of communication between services, systems, and clients. Given their central role, ensuring the functionality, security, and reliability of APIs is crucial. That’s where API testing comes in. API testing ensures that the APIs function as expected, deliver correct data, and handle errors properly. In this blog post, we’ll explore Rest Assured , a powerful open-source Java library that makes API testing simpler and more efficient. Whether you're new to API testing or looking to refine your existing process, Rest Assured provides a fluent and flexible approach for testing RESTful APIs . What is Rest Assured? Rest Assured is a Java-based library designed for testing RESTful web services. It abstracts much of the complexity of working with HTTP requests ...

Spring boot API Unit Test cases

JUnit5 with Mockito Test Cases for Spring Boot 3 APIs in Aviation Industry JUnit5 with Mockito Test Cases for Spring Boot 3 APIs in Aviation Industry Table of Contents 1. Introduction 2. Overview of Spring Boot 3 and JUnit5 3. Introduction to Mockito for Unit Testing 4. Flight Booking System Architecture 5. Setting Up the Environment 6. Writing Test Cases with JUnit5 and Mockito 7. Code Examples 8. Conclusion 9. Download Sample Project (ZIP) 1. Introduction This white paper demonstrates how to write unit tests for a Spring Boot 3-based Flight Booking System using JUnit5 and Mockito. The goal is to ensure the correctness of controllers, services, and DAO components using effective unit testing strategies. 2. Overview of Spring Boot 3 and JUnit5 Spring Boot 3 offers enhanced performance and streamlined APIs. JUnit5 provides a flexible and powerful testing framework. Mockito simplifies mocking depen...

Data Migration at Trading Bank

Introduction At Charles Schwab, data management is crucial for maintaining operational efficiency and providing data-driven insights. A common requirement is the movement of data from a SQL (DB2) database to a NoSQL (MongoDB) database. This whitepaper explores two approaches for batch data migration: using Spring Batch Job and leveraging Azure Data Engineering tools. Spring Batch Job Approach Spring Batch is a robust framework for batch processing in Java. It supports large-scale data migrations with a fault-tolerant, scalable design. Below are key components of a Spring Batch Job: Job Configuration: XML or Java-based configuration for defining steps. ItemReader: Extracts data from DB2. ItemProcessor: Transforms data as needed. ItemWriter: Writes data into MongoDB. Advantages Fine-grained control over batch processing. Exception handling and retry mechanisms. Parallel processing and partitioning support. Challenges Requires Java expertise...

Migration from mySQL to Postgresql

Introduction With Oracle's acquisition of MySQL, many organizations are considering migrating their backend databases to PostgreSQL. PostgreSQL, an advanced open-source relational database, offers numerous advantages over MySQL, especially when used as the backend for Spring Boot APIs. This whitepaper explores the reasons for this migration and the benefits it offers. Key Reasons for Migration 1. Licensing and Vendor Lock-In After Oracle's acquisition, MySQL has undergone changes in licensing, with restrictions introduced under the Oracle MySQL Enterprise Edition. PostgreSQL remains fully open-source, providing organizations with freedom from vendor lock-in. 2. Advanced Features PostgreSQL offers powerful advanced features that MySQL lacks, including: Support for advanced data types (JSONB, XML, Arrays). Robust ACID compliance for data consistency. Window functions, CTEs, and full-text search. 3. Enhanced Performance and Scalability PostgreSQL's query...