zero gravitySOLUTIONS
INSIGHTS / THE ENGINEERING BEHIND THE DECISION

Good questions.
Better systems.

Work through a real engineering decision: automate a workflow, scope a customer portal, review an existing prototype, understand cloud costs or choose a delivery partner. Each guide connects the technical detail to a useful next step.

160engineering guides
with diagrams, examples, and tools
START WITH A REAL DECISION

What will AI automation actually cost?

Change the workload, review effort, and operating costs. See what happens to the economics before you commit to a build.

Explore the cost worksheet
Model usage+Human review+Exceptions & operations+Setup allocation
Cost per completed task

The engineering library.

Clear explanations. Useful decisions.

06Engineering partnerships
Review experiment · 7 min read

Make AI-assisted engineering easy to review

Review AI-assisted code and inherited prototypes through business invariants, counterexamples and a keep, repair or investigate evidence record.

07Java & performance
Execution isolation guide · 5 min read

CPU-heavy work in WebFlux

Isolate CPU-heavy work in WebFlux using explicit execution budgets, bounded admission, cooperative cancellation, and a representative mixed-route experiment.

08Java & performance
Diagnostic walkthrough · 5 min read

Finding blocking calls in WebFlux

Trace blocking work in a WebFlux request using a controlled fixture, BlockHound, thread evidence, and a bounded isolation strategy.

10Java & performance
Capacity experiment · 5 min read

Virtual threads still need database limits

Plan Java virtual-thread workloads around finite database connections, admission limits, transaction duration, and a fixed-capacity load experiment.

11Backend & reliability
Crash-injection test plan · 5 min read

Testing every outbox crash boundary

Test a transactional outbox with crash injection before commit, after publication, during lease expiry, and across consumer acknowledgement boundaries.

12SaaS engineering
Integration contract guide · 6 min read

A third-party integration contract you can operate.

Build an operable third-party API contract covering tenant identity, accepted outcomes, response validation, webhook ordering, sandbox gaps, and reconciliation.

13Architecture
Architecture decision guide · 5 min read

Infrastructure as code ownership across teams.

Choose Terraform or AWS CDK through resource ownership, state custody, provider coverage, review artifacts, and an import-and-handover rehearsal.

14AI & automation
Security test guide · 5 min read

Test tenant isolation in vector retrieval

Build trusted tenant filters, review PostgreSQL row security and approximate-index behavior, and run an adversarial cross-tenant retrieval harness.

17Cloud & operations
Workflow ownership comparison · 5 min read

Step Functions or a job queue?

Choose Step Functions or BullMQ around durable workflow state, human callbacks, retry ownership, operation identity, and the cost of running recovery.

18Backend & reliability
AWS message-group walkthrough · 5 min read

SQS FIFO ordering by business group

Design SQS FIFO message groups, deduplication identities, visibility handling, and Lambda partial batch failures around business ordering requirements.

19Java & performance
Benchmark methodology · 4 min read

A fair Spring MVC and WebFlux benchmark

Compare Spring MVC and WebFlux with declared workloads, pinned environments, equal resource budgets, overload tests, and reproducible reporting.

25Engineering partnerships
Acceptance agreement · 5 min read

Agree on what delivered really means

Build a shared definition of done that separates merged code, release readiness, customer availability, acceptance evidence, and operational ownership.

29AI & automation
Capacity worksheet · 5 min read

Plan capacity for a shared LLM endpoint

Budget requests, input tokens, output tokens, concurrency, and tenant fairness with a worked admission example and overload policy.

32SaaS engineering
Rollout planning guide · 6 min read

Roll out a feature to the right customer cohort.

Roll out account-scoped SaaS features with stable allocation, prerequisite migrations, exposure evidence, advance gates, and compatible fallback states.

35SaaS engineering
Audit record design · 5 min read

An audit trail that explains the action

Design a SaaS audit trail around actor, authority, intent, target revision, and outcome, with transactional recording, tenant access, and deliberate retention.

38Cloud & operations
Upload lifecycle design · 5 min read

S3 uploads that remain correct after retries

Design S3 presigned uploads with tenant-owned intent, unique keys, object-version verification, duplicate event handling, processing gates, and cleanup.

39SaaS engineering
Checkpoint design · 6 min read

Building a resumable SaaS import

Design a resumable SaaS data import with immutable inputs, staged validation, durable checkpoints, duplicate-safe writes, and interruption tests.

43Backend & reliability
Retention worksheet and drill · 5 min read

Redis memory pressure in job queues

Budget Redis queue memory across waiting, delayed, completed, failed, and diagnostic data; configure retention and test safe admission failure under pressure.

44Backend & reliability
Calendar policy guide · 5 min read

Recurring jobs across daylight-saving changes

Define recurring job behavior for missing and repeated local times using explicit calendar policies, occurrence identities, and timezone fixture tests.

45Java & performance
Admission-control walkthrough · 5 min read

Reactor backpressure at an API boundary

Connect Reactor demand to external API capacity using bounded concurrency, explicit rate limits, finite buffering, and cancellation-aware tests.

46Java & performance
Retained-memory experiment · 5 min read

Memory growth behind slow reactive consumers

Find retained memory in reactive Java streams by tracing queue ownership, subscription counts, payload expansion, demand, and cancellation cleanup.

48SaaS engineering
State transition guide · 5 min read

Optimistic React updates after failure

Design optimistic React interfaces that distinguish rejected writes from unknown outcomes, preserve later edits, and reconcile server state safely.

49SaaS engineering
Interaction acceptance guide · 5 min read

React accessibility as a delivery condition

Build React accessibility acceptance around keyboard and focus behavior, dialog semantics, validation announcements, automated checks, and manual assistive-technology review.

50Cloud & operations
Architecture decision guide · 5 min read

RDS Proxy in a serverless application.

Design RDS Proxy around transaction occupancy, session pinning, client pools, authentication, and controlled connection-pressure tests.

57Backend & reliability
Outage simulation · 5 min read

Preventing queue retry storms

Contain retries after a dependency outage with shared budgets, bounded backoff, jitter, recovery admission, and an explicit outage simulation.

59Product data
Metric ownership guide · 5 min read

Metric ownership when three dashboards disagree.

Resolve conflicting dashboards with metric definition records, clear ownership, shared semantic rules, and edge-case fixtures that distinguish different questions.

62AI & automation
Prioritization worksheet · 6 min read

Choose the first AI workflow in a SaaS product

Compare candidate workflows using evidence readiness, error consequences, review capacity, and uncertain value ranges before committing to a pilot.

64Product data
Experiment instrumentation · 5 min read

Track real experiment exposure in PostHog

Separate assignment, eligible exposure, and outcomes at the correct account grain, with a synthetic ledger and custom exposure event contract.

66SaaS engineering
Workload comparison · 5 min read

PostgreSQL or MongoDB for versioned documents?

Compare PostgreSQL and MongoDB for a versioned document workflow using the same revision, approval, reporting, indexing, and concurrency requirements.

67Backend & reliability
Schema transition walkthrough · 5 min read

PostgreSQL migrations across application versions

Plan PostgreSQL expand-contract migrations with compatible application releases, guarded backfills, constraint validation, lock budgets, and delayed schema removal.

68Cloud & operations
Recovery protocol · 4 min read

A restore drill for a PostgreSQL-backed SaaS.

Test PostgreSQL recovery through isolated restore, target-time fixtures, application integrity checks, and external side-effect reconciliation.

70SaaS engineering
Responsibility map · 4 min read

Does Next.js need a separate business API?

Decide when a Next.js SaaS needs a separate API using a responsibility map, transaction boundaries, deployment constraints, and an incremental extraction plan.

71SaaS engineering
Preview lifecycle design · 5 min read

Preview environments with isolated data

Design Next.js preview environments with unique identities, synthetic tenant data, isolated credentials, safe callbacks, build-time configuration checks, and cleanup.

72SaaS engineering
Module extraction guide · 5 min read

NestJS modules around business capabilities

Design a NestJS capability boundary using a reservation example, narrow exported providers, transaction ownership, and dependency checks.

73SaaS engineering
API acceptance workflow · 5 min read

Contract tests for NestJS APIs and clients

Test a NestJS API contract across OpenAPI generation, runtime validation, serialization, generated clients, and meaningful success and failure fixtures.

76SaaS engineering
Request contract guide · 5 min read

Tenant-aware API idempotency

Design a multi-tenant API idempotency contract with scoped keys, request fingerprints, atomic claims, replay authorization, and concurrent-request tests.

77Architecture
Architecture decision guide · 6 min read

Backup recovery or a second live region.

Compare backup restoration and a warm secondary Region across application capacity, replication, write authority, external dependencies, and failback.

78CI/CD & delivery
Dependency-aware CI design · 5 min read

Monorepo CI that checks affected applications

Design affected monorepo builds with a dependency graph, correct comparison revisions, shared-file invalidation, and a stable required-check gate.

79Backend & reliability
Index rollout review · 5 min read

Introducing a MongoDB index safely

Plan a MongoDB production index rollout with representative query plans, uniqueness checks, build-resource observation, hidden-index limits, and rollback criteria.

84Product data
Data correction guide · 4 min read

Late-arriving events in product metrics.

Handle event and arrival time, deduplicate retries, recompute affected days, and define correction windows with an original SQL fixture.

85Cloud & operations
Architecture decision guide · 5 min read

Choose Lambda or ECS Fargate for an API.

Compare Lambda and ECS Fargate API architecture through workload shape, runtime control, database occupancy, operating cost, and a bounded decision experiment.

88Backend & reliability
Compatibility rollout guide · 5 min read

Evolving Kafka events with old consumers

Change Kafka event schemas while old consumers and retained records remain: compatibility direction, semantic tests, rollout order, and replay fixtures.

89Backend & reliability
Partition design experiment · 5 min read

Kafka keys for account-level ordering

Design Kafka partition keys around account invariants, test hot-account skew, preserve processing order, and plan partition-count migrations.

90Java & performance
Recovery experiment · 5 min read

Testing JVM recovery after overload

Run a repeatable JVM overload test with declared arrival ramps, bounded failure injection, recovery criteria, backlog accounting, and runtime evidence.

91Java & performance
Dependency and transaction guide · 5 min read

Choosing a JDBC or R2DBC boundary

Choose JDBC or R2DBC using driver capabilities, transaction context, library dependencies, pool capacity, and a representative cancellation and rollback experiment.

92Java & performance
Latency diagnostic guide · 5 min read

Why Java p99 latency stays high

Investigate Java tail latency with explicit measurement boundaries, a reproducible synthetic distribution, queue-time decomposition, and targeted JFR evidence.

93Java & performance
Latency and capacity worksheet · 5 min read

Performance budgets for Java integrations

Set Java integration performance budgets across admission, pools, dependencies, retries, and response work, with explicit deadlines and capacity assumptions.

94SaaS engineering
Failure containment design · 5 min read

A kill switch for running integrations

Design an integration kill switch that controls new requests, queued work, in-flight calls, webhooks, stale configuration, and gradual recovery.

100CI/CD & delivery
Workflow contract guide · 5 min read

Reusable workflows with a clear contract

Design GitHub Actions reusable workflows with typed inputs, explicit outputs, minimal permissions, scoped secrets, and versioned caller compatibility.

101CI/CD & delivery
Defensive workflow review · 5 min read

Pull-request workflows and untrusted code

Review GitHub Actions pull-request trust boundaries across tokens, fork code, runners, caches, artifacts, and privileged follow-up workflows.

102CI/CD & delivery
Build evidence comparison · 5 min read

Caches and release artifacts have different jobs

Distinguish GitHub Actions caches from release artifacts using validity keys, clean-cache builds, provenance, integrity checks, and immutable promotion.

103CI/CD & delivery
Trust-boundary walkthrough · 5 min read

Deploying to AWS with GitHub OIDC

Configure GitHub Actions AWS OIDC around exact trust subjects, environment protections, least-privilege roles, short-lived sessions, and negative authorization tests.

104SaaS engineering
Requirement decision sheet · 6 min read

Firebase or a custom backend?

Choose Firebase or a custom backend for one product capability by testing authorization, transaction boundaries, query shape, offline behavior, and migration triggers.

105Cloud & operations
AWS responsibility map · 5 min read

EventBridge and SQS in one architecture

Combine EventBridge routing with SQS work ownership using explicit event identities, delivery and processing DLQs, retry budgets, and subscription outcome tracking.

109Architecture
Platform decision guide · 5 min read

Does your product need Kubernetes yet?

Decide whether EKS or ECS fits your product through platform requirements, managed operating modes, controller ownership, portability, and a reversible proof.

110CI/CD & delivery
Release identity walkthrough · 5 min read

Promoting ECS images by digest

Deploy ECS releases using immutable image digests, verified build evidence, separate environment configuration, task-definition review, and known-artifact rollback.

111Cloud & operations
Operating guide · 5 min read

Tracing one request across API queue and worker.

Trace API-to-SQS-to-worker execution with explicit carrier mapping, attempt identity, span links, sampling boundaries, and an ADOT/X-Ray deployment model.

118Backend & reliability
Triage and replay guide · 5 min read

Dead-letter queues need an owner

Operate dead-letter queues with explicit ownership, triage categories, replay eligibility, retention planning, and a controlled redrive procedure.

125Cloud & operations
Implementation guide · 5 min read

Cloudflare Workers at the application boundary.

Implement a Cloudflare Worker-to-origin contract with allowlisted routes, secret handling, placement choices, bounded retries, and account authorization.

126Cloud & operations
Request-path guide · 4 min read

Cloudflare at the edge of a SaaS application.

Design separate Cloudflare policies for public assets, private dashboards, and webhooks, with origin protection and two-account cache validation.

130Backend & reliability
Load experiment · 4 min read

Choosing a BullMQ concurrency limit

Tune BullMQ worker concurrency against database and provider capacity with a bounded load experiment, useful measurements, and rollout stop conditions.

131Backend & reliability
Operator runbook · 5 min read

Recovering jobs with uncertain side effects

An operator runbook for background job reconciliation: inspect operation identity, check provider evidence, resolve unknown outcomes, and replay safely.

132Product data
Identity guide · 4 min read

Account identity in B2B product analytics.

Model people, accounts, workspace switching, and membership history with an original event fixture and account-level analytics regression checks.

133SaaS engineering
Compatibility and sunset plan · 5 min read

API versioning for independent customer upgrades

Plan B2B API evolution with consumer compatibility fixtures, explicit semantic changes, version adapters, telemetry, and an actionable sunset process.

137Cloud & operations
Operating guide · 6 min read

Secrets rotation without a coordinated outage.

Rotate application secrets through provider validity, Secrets Manager versions, consumer refresh, pool behavior, and a realistic rollback exercise.

138Backend & reliability
Monitoring scenario design · 5 min read

Synthetic checks for integration outcomes

Design scheduled API integration checks with a synthetic tenant, bounded operations, stable identities, business assertions, cleanup, and actionable failure classification.

142AI & automation
Reporting architecture · 5 min read

Build a read-only AI reporting assistant

Constrain reporting queries with approved metric definitions, scoped data access, execution budgets, and result validation before narrative generation.

144AI & automation
Sales workflow guide · 5 min read

Qualify incoming leads with evidence in your CRM

Connect inbound lead interpretation to duplicate identity, qualification criteria, missing facts, and an owned sales handoff without automatic outreach.

153AI & automation
Measurement architecture · 5 min read

Measure AI cost per resolved request

Define request cohorts, billable attempts, reopen windows, and estimated-versus-actual costs with an event schema and reconciliation worksheet.

155AI & automation
Decision experiment · 4 min read

When a classifier is enough for the job

Compare rules, classification, and investigation with a three-task experiment that isolates whether dynamic tool use adds value.

157AI & automation
Interactive cost worksheet · 6 min read

AI automation costs: beyond the model bill.

Estimate AI automation costs with an interactive worksheet covering model calls, human review, exceptions, operations, and setup amortization.

From the archive.

Earlier writing on engineering and learning.

A GOOD CONVERSATION IS A GOOD START

Which workflow
comes next?

Bring a recurring task, a customer-care bottleneck, or an AI product idea.
Let’s define a useful first implementation.

Tell us about your project