Latest Updates

Documenting code, one commit at a time.

Seeding Initial Data for Tenant-Specific Features

Introduction

This post details the process of seeding initial data, specifically post examples, for tenant-specific features in our application. This approach allows for features like auto-generated posts or random content display that is tailored to each tenant.

The Need for Seed Data

When building multi-tenant applications, providing default or example data for each tenant can greatly

Read more

Refactoring for Efficiency: Sharing Tenant Setup Logic in Our Testing Suite

In large projects, repetitive code across numerous tests can lead to maintenance overhead and inconsistencies. We recently tackled this in our application by extracting common tenant setup logic into a reusable trait, significantly reducing code duplication and improving test maintainability.

The Problem: Duplicated Boilerplate

Our testing suite involved numerous tests that required setting

Read more

Optimizing Product Ranking and Data Aggregation in SQL

Introduction

This post delves into optimizing SQL queries for product ranking and data aggregation, focusing on common pitfalls and effective strategies to enhance performance and accuracy. We'll explore techniques to address memory errors, improve query speed, and ensure data integrity when dealing with complex relationships and large datasets.

Addressing Memory Errors in Ranking

Read more