Add Elastic APM integration.

https://www.elastic.co/guide/en/apm/agent/ruby/4.x/introduction.html
This commit is contained in:
evazion
2022-04-11 01:46:08 -05:00
parent 98b313f8de
commit f69847fc59
6 changed files with 37 additions and 9 deletions

View File

@@ -117,7 +117,7 @@ class SessionLoader
def authenticate_basic_auth
credentials = ::Base64.decode64(request.authorization.split(' ', 2).last || '')
login, api_key = credentials.split(/:/, 2)
DanbooruLogger.add_attributes("request.params", login: login)
DanbooruLogger.add_attributes("param", login: login)
authenticate_api_key(login, api_key)
end