Search
Lessons (40)
- Microkernel (Plugin) Architecture
… the ONLY thing plug-ins import from the core export interface MarkdownPlugin { name: string; version: string; / Transform raw …
- O — Open/Closed Principle
… Add new features by plugging in new code instead of editing code that already works. The big idea …
- N+1 Queries, Loading & Pagination
… img/database/n-plus-one.svg) Three correct loading strategies Need Use Watch out for --- --- --- One related row …
- Hexagonal Architecture (Ports & Adapters)
… plugged into ports on every side](/img/architecture/hexagon.svg) 💡 Why a hexagon? No magic in the number …
- TypeScript Essentials
… idea Imagine electrical plugs with no shapes: every plug fits every socket, and you only find out it …
- YAGNI: You Aren't Gonna Need It
… nobody asked for PDF, XML, plugins or custom delimiters class ExportEngine { constructor({ format = "csv", delimiter = ",", encoding = "utf-8 …
- Structural Patterns: How to Connect Objects
… Every oak shares one 3D model and texture; each tree only stores its own position. Problem: huge numbers …
- Kafka vs RabbitMQ & the Kafka Ecosystem
… filtering, mapping, joining streams, windowed aggregations, with exactly-once support. No separate cluster needed; it runs inside your …
- SOLID at a Glance
… Closed Add new behaviour by adding code , not editing old code. Plug a new lens onto a camera …
- Time, Consistency and Distributed Transactions
… Network partitions can create split brain: two owners act at once. For exclusive work, use a lease plus …
- API Gateway, BFF & Service Discovery
… One generic API serves nobody well. A BFF is a small backend tailored to one frontend , owned by …
- Helm, kubectl Cheat Sheet & Best Practices
… true capabilities: { drop: ["ALL"] } Plus: scan images, pull only from trusted registries, use NetworkPolicies, keep Secrets in a …
- Meaningful Names
… Use the right kind of word Different things need different grammar. Once you follow this, code reads like …
- Clean Architecture
… wire everything together, once js // main.js — the ONLY place that knows every concrete class const registerUser = new …
- Indexes, EXPLAIN & Query Plans
… I/O. Operational checklist Capture slow query fingerprints, not only raw SQL text. Compare p50 and p99. Refresh …
- REST API Design
… User not found } Checklist - [ ] Plural nouns, no verbs in paths - [ ] Correct methods and status codes - [ ] One consistent error …
- What Is Software Architecture?
… ADRs Six months from now, someone will ask "Why on earth did we pick MongoDB?" An Architecture Decision …
- Services & Ingress
… internal only"] i1[pod in cluster] -- s1{{shop-api}} -- p1[pods] end subgraph NP["NodePort: a port on …
- Choosing an Architecture
… from inside one app to the whole system](/img/architecture/styles-map.svg) Two decisions, not one Most …
- Data in Microservices: Sagas & the Outbox Pattern
… no shared tables, so no cross-service ACID transactions. - Avoid 2PC; use sagas : local transactions plus compensating actions …
- Database Relations & Foreign Keys
… matters --- --- --- --- One-to-one User has one profile profiles.user id UNIQUE plus foreign key One-to-many …
- Which Pattern Do I Need?
… depends on conditions"] -- F[Factory] P2["Constructor has too<br/ many parameters"] -- B[Builder] P3["Need matching families …
- D — Dependency Inversion Principle
High-level business logic should depend on abstractions, not on concrete details like databases or email providers. The …
- Comments & Formatting
… lists here are always < 10 items and it's stable Warning // Not thread-safe. Call only from the …
- Brokers, Replication & Durability
… If the building with the master burns down, one of the up-to-date copies becomes the new …
- Kubernetes Cluster Architecture
… one namespace per team or per environment ( dev , staging ), with ResourceQuotas and RBAC permissions per namespace. Managed vs …
- Deployments, ReplicaSets & Rollouts
… A pod dies → it creates a new one. - A Deployment manages ReplicaSets: each new version gets a new …
- Pods
… network, provided by the CNI plugin). Multi-container patterns Sidecar A helper container that extends the main one …
- Trees & Binary Search Trees
… one person at the top, each person has zero or more people below them, and nobody reports to …
- JavaScript Essentials: Event Loop, Closures & this
… ONE task if (timeToRender()) render(); // ~every 16 ms } ⚠️ Never block the stack. A 2-second loop means no …
- Message Queues & RabbitMQ
… Email, analytics and CRM all want to know. RabbitMQ in one picture In RabbitMQ, producers never send directly …
- Topics, Partitions & Offsets
… the unit of parallelism Each partition is an ordered, append-only log stored on one broker (plus copies …
- Kafka Producers
… But producers and consumers must agree on it. Format Pros Cons --- --- --- JSON Human-readable, easy Larger, no enforced …
- MVC, MVP & MVVM
… no UI framework needed const fakeView = { showError: vi.fn(), goToDashboard: vi.fn() }; await new LoginPresenter(fakeView, fakeAuth).onLoginClicked …
- Onion Architecture & Clean vs Hexagonal vs Onion
… Outer rings depend on inner rings, never the other way round. Infrastructure (databases, UI, frameworks) is the outer …
- Authentication, Authorization & API Security
… never in plain text mermaid flowchart LR P["password123"] -- H["bcrypt / argon2<br/ + random salt<br/ + slow on …
- Resilience Patterns
… never wait forever Every network call needs a timeout. Without one, a hung dependency holds your threads, connections …
- Normalization & Denormalization
… it represents a different business fact. Third Normal Form (3NF): no non-key depends on another non-key …
- React Hooks in Practice
… never inside if , loops or nested functions. 2. Only call hooks from React functions (components or custom hooks …
- Next.js Rendering: CSR, SSR, SSG, ISR & Server Components
… JSON Note over B: ✅ page visible (late) ✅ Rich interactivity, cheap hosting (static files). ❌ Slow first paint on slow …