iOS · Open source · Six rules for error handling in ios-opensource that I settled on

3
IOr/ios-opensource·posted by alice_dev·3 days agoReview

Six rules for error handling in ios-opensource that I settled on

Some background first. Our setup is ios-opensource plus three downstream services, seven figures of daily requests, peaking around nine in the evening.

One last trap: in container environments remember to adjust the memory-related parameters in step. Otherwise the host limit and the process expectation disagree, and the symptom is intermittent, unreproducible failure.

Documentation first44%
Source code first28%
Just ask someone17%
Run a demo and learn by error11%

5 votes total

2 comments

2 comments

M
Mmike_xu·3 minutes ago

Has anyone run a controlled experiment? I did, reducing it to a single variable, and the difference was 4% — within noise. So I suspect the main cause is something else.

391
Rran_bo·12 minutes ago

Worth learning from this debugging approach. We went straight at the logs and took a much longer route.

151

This is the post detail page /en/c/ios-opensource/post/p12. Posts and comments are generated deterministically from a seeded PRNG, so the same post always renders the same content and the link can be shared, reloaded and indexed. In production this page reads MySQL for the post, Redis for hot-post caching, and fetches the whole comment tree in a single query on the path column.

See the database schema →