OpenTelemetry gives you one standard way to see inside a distributed system.
3 part flow
Instrument: SDK in your app emits traces, metrics, logs
Collect: the OTel Collector receives and processes them
Export: ship to Jaeger, Prometheus, Grafana
Thanks @Hiteshdotcom for the video
Three ways to persist data in Docker:
Volume: Docker manages the path. Survives restarts. Best for databases.
Bind mount: maps a host path into the container. Good for local dev.
tmpfs: RAM only . Gone when container stops.
Volumes for prod. Bind mounts for dev. tmpfs rarely.
Containers on the same machine can't talk to each other by default.
Put them on a user-defined bridge network ,they can reach each other by container name.
No IPs. No hardcoding. Just name resolution.
This is how docker compose networking works under the hood.
Container keeps crash-looping and you can't exec into it.
docker exec doesn't work β it's not running long enough.
Fix:
docker run --entrypoint sh <image>
Overrides the entrypoint. Drops you into a shell. Container stays up.
Debug from the inside.
In Linux, being "nice" means giving up CPU time.
Niceness ranges from -20 to 19.
High niceness (19) = low priority. Polite process.
Low niceness (-20) = high priority. Greedy process,demands CPU.
Most databases don't lock rows on reads.
They keep multiple versions of the same row instead.
Each transaction sees the snapshot from when it started. Reads don't block writes. Writes don't block reads.
That's MVCC. Concurrency without locks.
Shipped KVSDB today.
Redis-compatible key-value store β but the internals are completely different.
Kafka is the WAL. RocksDB materializes state from it. Writes go to the log first, always.
Built the RESP parser, TCP server, crash recovery, TTL, and snapshots from scratch.
System Design 101: Key-based partitioning guarantees order but risks hot partitions. If you hash by 'user_id' and one user goes viral, that Kafka broker will choke. Always analyze data skew before picking a partition key. Strict ordering vs throughput is the real tradeoff.
In Kafka, every partition has 1 Leader and multiple Followers. All read and write traffic goes ONLY to the Leader. Followers just copy data. If the Leader goes down, Kafka automatically elects a new one from the In-Sync Replicas (ISR) to prevent downtime.
Kafka partitions dictate your max parallelism. But adding more won't fix a bad setup.
No Key -> Round Robin. Even load, zero order guarantee.
With Key -> Key-based. Strict order per key, but risks hot partitions.
Align your strategy with your throughput requirements
@vivoplt Code is just the final output. The real value is in knowing what to build and why. companies don't hire people just to type code. They hire people to understand problems, make technical decisions, design systems, handle trade-offs, and deliver business outcomes.
Dev log:
Added point-in-time RocksDB checkpointing and automatic snapshot recovery.
Snapshots are versioned as snapshot_<unix_millis>, sorted chronologically, and the latest snapshot is restored if the active DB is empty on startup.
Small feature, big step toward durability.
Today I built the thing that talks RESP on port 6379.
Not redis-cli. Not a Redis client.
A Redis-compatible server. RESP parser, TCP listener, CQRS command routing.
GET reads from RocksDB. SET writes to Kafka WAL first.
Writes don't exist until the log says they do.
Redis is not a cache library.
It's a server process running somewhere else.
redis.get('user:1') doesn't read memory. It goes: App β Client Library β RESP β TCP β Redis Server β RAM
The moment I understood this β RESP, wire protocols, client-server arch all clicked.
Replaying from event #1 sounds fine.
Until your log has 50 million events.
Snapshot = state at a point in time. On restart, load it. Replay only what came after.
The log is still source of truth. You just stop reading it from page 1.