commercialhaskell/stackage-server

Slow responses for package documentation

kerscher opened this issue · 2 comments

When accessing pages with routes such as /:snapshot/package/:package-name and /:snapshot/docs, response times and failure rates are much higher than other pages.

For /:snapshot/docs, the difference is more than double the time it takes to access other pages.

Indices added based on load testing data and correspondent handlers query usage. Besides /package/:package-name, routes using the following handlers improved, sometimes up to 30–50%:

  • getPackageR
  • getAllSnapshotsR
  • getStackageHomeR (!!!)

The big offenders now are getPackageBadgeR and getBranchFeedR — the last one by far the biggest offender.