Trading Infrastructure
monitoring and alerting for algo infrastructure - grafana + prometheus setup
realized last month that i had a massive blind spot in my infrastructure: monitoring. my algos were running 24/7 but i had no idea if they were running WELL until i checked PnL at end of day. that’s like driving with your eyes closed and checking if you crashed when you stop.
exchange connectivity layer - handling binance, kraken, and coinbase in one abstraction
·1665 words
one of the most annoying parts of crypto algo trading is that every exchange has a different API. different auth schemes, different rate limits, different order types, different error codes. writing strategy logic for each exchange separately is a nightmare and a maintenance disaster.
redis for market data - why i ditched postgres
·1319 words
moved all my real-time market data from postgres to redis about 8 weeks ago. latency dropped from ~15ms to sub-millisecond. should’ve done this way earlier.
the postgres problem # when i first built my algo infrastructure i stored everything in postgres because that’s what i knew. tick data, order book snapshots, greeks, everything went into timescaledb (postgres extension for time-series).
slippage models - making backtests actually realistic
·1251 words
been thinking about slippage modeling a lot lately. most backtest frameworks have absolute dogshit slippage assumptions - either zero (lmao) or some fixed percentage that doesn’t scale with order size or volatility.
redis timeseries - cutting latency from 45ms to 8ms
·740 words
just finished a redis optimization project.
latency went from 45ms to 8ms.
here’s how.
the problem # market data pipeline was bottlenecking at redis.
ubiquiti 10gbe upgrade - network infrastructure overhaul
finally upgraded the home network.
10gbe backbone. no more bottlenecks.
the problem # running 4 Dell servers, 3 workstations, NAS, and market data feeds.
interactive brokers api - 2 years deep review
·600 words
been on IB for 2 years now.
primary broker for options and futures.
here’s what I’ve learned.
why IB # pros:
polygon.io vs thetadata - options data deep comparison
·470 words
been running both for 8 months now.
time for an honest comparison.
why both # polygon.io: primary equities and options quotes
timescaledb optimization - 3 million rows per day
been putting this off for months.
timescaledb getting slow. finally fixed it.
the problem # my options flow data pipeline ingests about 3 million rows per day.