go easy on rate limits
This commit is contained in:
parent
9c2a7c5883
commit
9bed58ae79
|
@ -19,8 +19,8 @@ object Setup extends LilaController with TheftPrevention {
|
|||
|
||||
private def env = Env.setup
|
||||
|
||||
private val FormRateLimit = new lila.memo.RateLimitByKey(1 second)
|
||||
private val PostRateLimit = new lila.memo.RateLimitByKey(1 second)
|
||||
private val FormRateLimit = new lila.memo.RateLimitByKey(500 millis)
|
||||
private val PostRateLimit = new lila.memo.RateLimitByKey(500 millis)
|
||||
|
||||
def aiForm = Open { implicit ctx =>
|
||||
if (HTTPRequest isXhr ctx.req) {
|
||||
|
|
|
@ -24,7 +24,7 @@ private[lobby] final class SocketHandler(
|
|||
socket: ActorRef,
|
||||
uid: String,
|
||||
member: Member): Handler.Controller = {
|
||||
lazy val RateLimit = new lila.memo.RateLimitGlobal(2 seconds)
|
||||
lazy val RateLimit = new lila.memo.RateLimitGlobal(1 second)
|
||||
PartialFunction {
|
||||
case ("p", o) => o int "v" foreach { v => socket ! PingVersion(uid, v) }
|
||||
case ("join", o) => RateLimit {
|
||||
|
|
Loading…
Reference in a new issue