racket / racket-pkg-website

A frontend for the Racket Package Catalog.
Other
11 stars 16 forks source link

Keep forms alive via a larger continuation memory threshold #80

Closed jryans closed 2 years ago

jryans commented 2 years ago

The LRU continuation manager's memory threshold was set to 128 MiB, but this is too low in practice, at least for the production service with recent versions of Racket, where current-memory-use is in the range of 200 - 350 MiB.

When the threshold is too low, all continuations expire after 2 minutes. In the case of the package creation form, it's quite likely you'll spend more than that time filling out the form, so this meant you'd have to start over and rush through quickly to get a new package added.

With this tuned memory value in place, most continuations should now stay alive for the maximum lifetime of 4 hours, which is much more usable.

Fixes https://github.com/racket/racket-pkg-website/issues/76

samth commented 2 years ago

This looks obviously right to me. Thanks for investigating.

jryans commented 2 years ago

@samth I've added logging when expired continuations are used.

jeapostrophe commented 2 years ago

Thanks!

jryans commented 2 years ago

Thanks for the review! I'll update the server to deploy this fix.

jryans commented 2 years ago

Deployment complete, fix verified on the production instance.

racket-discourse-github-bot commented 2 years ago

This pull request has been mentioned on Racket Discussions. There might be relevant details there:

https://racket.discourse.group/t/package-server-new-package-workaround/530/10