mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
increase rate limit threshold on pdf downloads
This commit is contained in:
parent
16670cb3e3
commit
4e8eebb482
2 changed files with 3 additions and 3 deletions
|
@ -50,7 +50,7 @@ module.exports = CompileController =
|
||||||
else
|
else
|
||||||
rateLimitOpts =
|
rateLimitOpts =
|
||||||
endpointName: "full-pdf-download"
|
endpointName: "full-pdf-download"
|
||||||
throttle: 30
|
throttle: 50
|
||||||
subjectName : req.ip
|
subjectName : req.ip
|
||||||
timeInterval : 60 * 5
|
timeInterval : 60 * 5
|
||||||
RateLimiter.addCount rateLimitOpts, callback
|
RateLimiter.addCount rateLimitOpts, callback
|
||||||
|
|
|
@ -135,7 +135,7 @@ describe "CompileController", ->
|
||||||
@req.query = {}
|
@req.query = {}
|
||||||
@RateLimiter.addCount.callsArgWith(1, null, true)
|
@RateLimiter.addCount.callsArgWith(1, null, true)
|
||||||
@CompileController.proxyToClsi = (project_id, url)=>
|
@CompileController.proxyToClsi = (project_id, url)=>
|
||||||
@RateLimiter.addCount.args[0][0].throttle.should.equal 30
|
@RateLimiter.addCount.args[0][0].throttle.should.equal 50
|
||||||
done()
|
done()
|
||||||
@CompileController.downloadPdf @req, @res
|
@CompileController.downloadPdf @req, @res
|
||||||
|
|
||||||
|
@ -144,7 +144,7 @@ describe "CompileController", ->
|
||||||
@req.query = {pdfng:false}
|
@req.query = {pdfng:false}
|
||||||
@RateLimiter.addCount.callsArgWith(1, null, true)
|
@RateLimiter.addCount.callsArgWith(1, null, true)
|
||||||
@CompileController.proxyToClsi = (project_id, url)=>
|
@CompileController.proxyToClsi = (project_id, url)=>
|
||||||
@RateLimiter.addCount.args[0][0].throttle.should.equal 30
|
@RateLimiter.addCount.args[0][0].throttle.should.equal 50
|
||||||
done()
|
done()
|
||||||
@CompileController.downloadPdf @req, @res
|
@CompileController.downloadPdf @req, @res
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue