Skip to content

Commit

Permalink
remove rate limiter and slow-down middleware (github#26709)
Browse files Browse the repository at this point in the history
* remove rate limiter and slow-down middleware

* update package-lock.json after node-fetch removal in main
  • Loading branch information
peterbe authored Apr 5, 2022
1 parent e719039 commit a4def10
Show file tree
Hide file tree
Showing 6 changed files with 80 additions and 232 deletions.
2 changes: 0 additions & 2 deletions docker-compose.prod.tmpl.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ services:
HEROKU_APP_NAME: ${HEROKU_APP_NAME}
ENABLED_LANGUAGES: ${ENABLED_LANGUAGES}
DEPLOYMENT_ENV: ${DEPLOYMENT_ENV}
RATE_LIMIT_MAX: ${RATE_LIMIT_MAX}
SLOW_DOWN_MAX: ${SLOW_DOWN_MAX}
HEROKU_PRODUCTION_APP: true
PORT: 4000
DD_AGENT_HOST: datadog-agent
Expand Down
4 changes: 0 additions & 4 deletions middleware/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import abort from './abort.js'
import timeout from './timeout.js'
import morgan from 'morgan'
import datadog from './connect-datadog.js'
import rateLimit from './rate-limit.js'
import slowDown from './slow-down.js'
import cors from './cors.js'
import helmet from 'helmet'
import csp from './csp.js'
Expand Down Expand Up @@ -212,8 +210,6 @@ export default function (app) {
}

// *** Early exits ***
app.use(slowDown)
app.use(rateLimit)
app.use(instrument(handleInvalidPaths, './handle-invalid-paths'))
app.use(asyncMiddleware(instrument(handleNextDataPath, './handle-next-data-path')))

Expand Down
33 changes: 0 additions & 33 deletions middleware/rate-limit.js

This file was deleted.

20 changes: 0 additions & 20 deletions middleware/slow-down.js

This file was deleted.

Loading

0 comments on commit a4def10

Please sign in to comment.