App Design · News · I built a small tool with app-design-news — code is open, feedback welcome

295
ADr/app-design-news·posted by ops_wang·3 days agoTooling

I built a small tool with app-design-news — code is open, feedback welcome

Most app-design-news articles stop at "how to use it" and never cover "when not to use it". This is an attempt at the second half.

What genuinely surprised me was the tail. The average looked great while P99 jumped by an order of magnitude past some threshold. The cause was not app-design-news itself but our upstream connection reuse — the load test traffic was too clean and hid the long-tail requests.

Self-host — full control44%
Managed service — less work28%
Hybrid: core self-hosted17%
Not decided yet11%

502 votes total

119 comments

119 comments

M
RraseOP·2 days ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

516
Llinlin·2 days agoedited

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

481
Oops_wang·2 days ago

Saved. I am reworking this area this week — this saves a lot of wrong turns.

457
Wwinter·2 days ago

Saved. I am reworking this area this week — this saves a lot of wrong turns.

413
Hhuang_ke·2 days ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

413
Oops_wang·2 days ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

388
Wwinter·2 days agoedited

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

366
Rran_bo·2 hours agoedited

Saved. I am reworking this area this week — this saves a lot of wrong turns.

422
Sslow_query·1 hour ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

362
Zzhu_zong·3 minutes ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

4
Ddev_zhou·12 minutes agoedited

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

444
Rrase·yesterday

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

394
NnikicOP·2 days ago

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

478
Mmike_xu·2 days agoLevel 6

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

1
Hhuang_ke·2 days ago

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

6
Kkite·2 days agoeditedLevel 6

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

1
Ddev_zhou·3 minutes ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

113
Bbob_chen·12 minutes ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

96
KkiteOP·12 minutes ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

4
Llinlin·2 days agoedited

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

23
Lli_ming·2 days agoLevel 6

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

406
Ttang_haoMod·2 days ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

34
Sslow_query·2 days ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

27
Llinlin·28 minutes ago

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

8
Wwinter·2 days ago

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

95
Rrase·2 days agoLevel 6

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

478
Mmike_xu·2 days agoLevel 6

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

281
Lli_ming·2 hours agoeditedLevel 6

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

198
Cchen_dev·2 days agoLevel 6

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

169
Nnikic·12 minutes agoLevel 6

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

61
Zzhu_zong·2 days ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

5
Ddev_zhou·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

1
Cchen_dev·5 hours ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

41
Aalice_dev·2 days agoLevel 6

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

1
Bbob_chen·2 days ago

Saved. I am reworking this area this week — this saves a lot of wrong turns.

3
Hhuang_ke·3 minutes ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

7
Sslow_query·2 hours ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

172
Llinlin·2 days ago

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

361
Sslow_query·1 hour ago

Saved. I am reworking this area this week — this saves a lot of wrong turns.

343
Aalice_devOP·1 hour agoedited

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

272
Nnikic·2 days ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

37
Rran_bo·2 days 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.

311
Lli_ming·3 minutes ago

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

298
Cchen_devOP·2 days 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.

157
Oops_wang·2 days agoedited

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

61
Ttang_hao·2 days ago

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

292
Hhuang_ke·5 hours ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

12
Nnikic·2 days ago

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

249
Mmike_xu·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

230
Rran_bo·2 days ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

199
NnikicMod·2 days 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.

174
Oops_wang·2 days 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.

245
Hhuang_ke·yesterday

Saved. I am reworking this area this week — this saves a lot of wrong turns.

213
Hhuang_keOP·12 minutes ago

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

131
Rrase·2 days ago

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

178
Oops_wang·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

171
Ddev_zhou·2 days ago

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

158
Wwinter·2 days ago

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

157
Llinlin·2 days ago

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

214
Kkite·2 days agoedited

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.

35
Mmike_xuOP·2 days ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

84
Ddev_zhou·2 days ago

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

140
Kkite·just now

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

114
Ttang_hao·2 days ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

201
Hhuang_ke·2 days ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

483
Ddev_zhou·1 hour agoedited

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

4
NnikicOP·2 days ago

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

109
Mmike_xu·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

69
Mmike_xu·2 days ago

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

108
Llinlin·2 hours ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

99
Llinlin·2 days ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

97
Rran_boOP·2 days ago

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

35
Sswoole_lee·2 days ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

128
Nnikic·2 days ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

90
Hhuang_ke·28 minutes ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

89
Rrase·yesterday

Saved. I am reworking this area this week — this saves a lot of wrong turns.

74
Kkite·3 minutes ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

87
Zzhou_yi·3 minutes agoedited

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.

519
Sslow_query·12 minutes ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

227
KkiteOP·2 days ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

154
Lli_ming·2 days ago

Agreeing with the above. One addition: with this option enabled the GC count in your metrics doubles, so adjust the alert threshold at the same time or it will keep firing.

37
Cchen_dev·3 minutes ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

2
Sslow_query·2 days ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

268
Oops_wang·3 minutes ago

There is actually a simpler fix that needs no architecture change: move this check up to the gateway and the problem disappears. The cost is one extra lookup at the gateway.

40
Kkite·2 days ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

88
LlinlinOPMod·2 days agoedited

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

19
Hhuang_ke·2 days ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

75
Rran_boOP·2 days ago

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

110
Zzhu_zongOP·2 days ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

3
Lli_ming·2 days ago

I see point 3 differently. The trade-off depends on your read/write ratio: read-heavy with little writing means caching actually widens the inconsistency window.

62
Cchen_dev·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

43
Nnikic·28 minutes ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

12
Llinlin·2 days 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.

9
NnikicOP·3 minutes ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

463
Rran_bo·5 hours ago

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

5
Rrase·2 days ago

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

1
Wwinter·2 days agoedited

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

333
Hhuang_ke·2 days ago

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

1
Rrase·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

119
Rrase·2 days agoedited

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

1
Kkernel_panic·28 minutes agoedited

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

3
Ttang_hao·2 days ago

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

2
Sswoole_lee·3 minutes ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

229
Sswoole_lee·3 minutes ago

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

2
Nnikic·3 minutes ago

Saved. I am reworking this area this week — this saves a lot of wrong turns.

1
Mmike_xu·2 days ago

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

161
Sslow_query·2 days ago

This is not a app-design-news problem, it is a usage problem. The docs say this API is not thread-safe and you must lock around it yourself.

224
Rran_bo·2 days 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.

5
Mmike_xu·2 days ago

A question: what changes in a container with a 512Mi memory limit? That is how we run it in production.

44
Ttang_hao·2 days ago

One counter-example: below app-design-news 7.4 the semantics of that code are different, so do not copy it verbatim. We got burned in staging and rolled back once.

331
Kkernel_panic·1 hour ago

Thanks for sharing real numbers — far more useful than the articles that only cover concepts.

199
Sslow_query·2 days agoedited

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

1
Ddev_zhou·2 days agoedited

I just read the app-design-news source — the author actually explains the reasoning in a comment, roughly "so that it degrades into predictable behaviour in extreme cases".

3
Aalice_dev·1 hour ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

1
Cchen_dev·28 minutes ago

Sharing our numbers, 8 cores 16GB, same scenario:

| Concurrency | P50 | P99 |
|---|---|---|
| 200 | 12ms | 88ms |
| 500 | 31ms | 340ms |

P99 clearly collapses at 500 concurrency, which lines up with your knee point.

475
Nnikic·2 days ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

4
Sslow_query·5 hours agoedited

This matches what we see in production. We only hit it past 3k QPS; the earlier load tests showed nothing — the test traffic was too clean, with no long-tail requests.

420
Mmike_xu·2 days ago

We have run this in production for two years without hitting it. That said, we never reached this scale, so our experience is not really evidence here.

8
Kkite·2 days ago

Can you give a minimal reproduction? I ran it locally for ten minutes and could not reproduce on macOS with the latest version.

1

This is the post detail page /en/c/app-design-news/post/p9. 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 →