We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2acbbdc commit 3c95623Copy full SHA for 3c95623
src/app.js
@@ -29,7 +29,11 @@ app.use(express.urlencoded({ extended: false }))
29
app.use(queryParser())
30
app.use(timeout())
31
app.use(cors())
32
-app.use(rateLimiter)
+
33
+/* istanbul ignore next */
34
+if (!ehAmbienteDeTestes) {
35
+ app.use(rateLimiter)
36
+}
37
38
app.disable('etag')
39
src/middlewares/rate-limiter.js
@@ -5,7 +5,7 @@ const { RateLimiterMemory } = require('rate-limiter-flexible')
5
const { aplicacaoExecutandoLocalmente } = require('../utils/ambiente')
6
7
const rateLimiter = new RateLimiterMemory({
8
- points: 250, // requests
+ points: 30, // requests
9
duration: 2 // segundo por IP
10
})
11
0 commit comments