remove dup monitoring

pull/9140/head
Thibault Duplessis 2021-06-09 08:55:35 +02:00
parent 0b289e64ae
commit 723cead7a3
2 changed files with 2 additions and 8 deletions

View File

@ -319,10 +319,6 @@ object mon {
def hit(client: String, result: String) =
counter("hcaptcha.hit").withTags(Map("client" -> client, "result" -> result))
}
object passwordHasher {
val encrypt = timer("security.passwordHasher.run").withTag("mode", "encrypt")
val decrypt = timer("security.passwordHasher.run").withTag("mode", "decrypt")
}
}
object tv {
object streamer {

View File

@ -32,10 +32,8 @@ final private class Aes(secret: Secret) {
}
import Cipher.{ DECRYPT_MODE, ENCRYPT_MODE }
def encrypt(iv: Aes.InitVector, b: Array[Byte]) =
lila.mon.chronoSync(_.security.passwordHasher.encrypt)(run(ENCRYPT_MODE, iv, b))
def decrypt(iv: Aes.InitVector, b: Array[Byte]) =
lila.mon.chronoSync(_.security.passwordHasher.decrypt)(run(DECRYPT_MODE, iv, b))
def encrypt(iv: Aes.InitVector, b: Array[Byte]) = run(ENCRYPT_MODE, iv, b)
def decrypt(iv: Aes.InitVector, b: Array[Byte]) = run(DECRYPT_MODE, iv, b)
}
private object Aes {