Search
Lessons (29)
- Inheritance
… void; // each channel fills this in } class EmailNotification extends Notification { protected deliver() { / SMTP / email API / } } class SmsNotification extends …
- Extending Kubernetes: CRDs, Operators and Admission
Teach Kubernetes new resource types, automate them with controllers, and enforce policy before objects are saved. Kubernetes is …
- Composition over Inheritance
… a class for every format + destination combination class PdfEmailReport extends Report {} class PdfS3Report extends Report {} class CsvEmailReport extends …
- L — Liskov Substitution Principle
… Square extends Rectangle In maths, a square is a rectangle. So inheritance seems natural: js class Rectangle { setWidth …
- Interfaces vs Abstract Classes
… string; } class CsvExporter extends DataExporter { protected readonly extension = "csv"; protected serialize(rows: Record<string, unknown []) { const headers = Object …
- SOLID at a Glance
Five design principles that keep object-oriented and modular code easy to extend, test and change. One picture …
- Clean Error Handling
… Custom error classes let them react precisely. js class AppError extends Error { constructor(message, statusCode) { super(message); this …
- TypeScript in Practice
… string } interface Repository<T extends Entity { findById(id: string): Promise<T null ; save(entity: T): Promise<void ; list …
- TypeScript Essentials
… User) { return Hi ${user.name} ; } interface type --- --- --- Object shapes ✅ ✅ Unions, tuples, primitives ❌ ✅ Extending extends & (intersection) Declaration merging ✅ ❌ 💡 Rule …
- JavaScript Language Fundamentals
… create(name) { return new this(name); } } class Dog extends Animal { bark() { return ${this.name}: woof ; } } const rex = Dog …
- OOP Mistakes and Interview Questions
… The classic violation is Penguin extends Bird where fly() throws. If a child can't honor the parent …
- Polymorphism
… speak() { return "..."; } } class Dog extends Animal { override speak() { return "Woof"; } } class Cat extends Animal { override speak() { return "Meow …
- Advanced TypeScript for Frontend
… simple component unreadable. ts type ApiResponse<T = T extends { id: infer Id } ? { item: T; id: Id } : never; type …
- Variables, Locals, Outputs, and Validation
… errors. Replace hard-coded values with a contract Extend the first local lab. Retain its terraform block, replace …
- Behavioral Patterns II: Chain, Template, Iterator, Mediator, Memento, Visitor
… save(records) { await db.insertMany(records); } } class CsvImporter extends DataImporter { read(path) { return fs.promises.readFile(path, "utf8 …
- StatefulSets, DaemonSets, Jobs and CronJobs
… For real databases, prefer an operator (see the extending lesson) or a managed service such as RDS. DaemonSet …
- KISS: Keep It Simple, Stupid
… AbstractNotificationStrategy { send() { throw new Error("abstract"); } } class EmailNotificationStrategy extends AbstractNotificationStrategy { / … / } const strategy = new NotificationStrategyFactory().create("email"); strategy.send …
- Abstraction
… string; } class SalesReport extends Report { protected title() { return "Monthly sales"; } protected fetchData() { return [120, 340, 90]; } protected format …
- DSA Interview Patterns Cheat Sheet
… last[1] = Math.max(last[1], end); // overlap → extend else merged.push([start, end]); } return merged; } mergeIntervals([[1 …
- Microkernel (Plugin) Architecture
… a minimal core system plus independent plug-in modules that extend it. ![Microkernel: a small core with plug …
- Event-Driven Architecture
… E) = Promise<void ; class EventBus { private handlers = new Map<string, Handler<any [] (); on<E extends { type: string } (type …
- Dynamic Programming
… dp[i - 1][j - 1] + 1 // chars match: extend the diagonal : Math.max(dp[i - 1][j], dp …
- AWS Messaging: Queues, Topics and Events
… Choose a timeout allowing normal completion, or extend it while working. It is not a guarantee against every …
- ACID, Transactions & Locks
… print all deadlocks = ON SQL Server system health Extended Events session → deadlock graph Alert on the deadlock rate …
- Design an E-Commerce Checkout
… While the payment is UNKNOWN , keep holding the stock (extend the reservation if needed). Releasing early risks charging …
- Jenkins in Production: Deploys, Docker and Scaling
… and back up JENKINS HOME . Try it yourself Extend your lesson 15 pipeline: build a Docker image tagged …
- Node.js and Express
… errors js import { z } from "zod"; class HttpError extends Error { constructor(status, message) { super(message); this.status = status …
- Kafka for Backend Services
… Lag grows and every later order waits. ts const MAX ATTEMPTS = 5; class PermanentError extends Error {} await consumer …
- Go Fundamentals
… composition instead of inheritance Go has no extends . Instead you embed one struct inside another, and its fields …