summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2019-09-25 11:59:00 +0100
committerErik Johnston <erik@matrix.org>2019-09-25 11:59:00 +0100
commitdc01cad690e3c6cb1ccb57995554dd93ab1636f2 (patch)
treebc61f4341fe6213875534b0d0a0c875c0e897916
parentNewsfile (diff)
downloadsynapse-dc01cad690e3c6cb1ccb57995554dd93ab1636f2.tar.xz
Add device and appservice tags
-rw-r--r--synapse/api/auth.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/api/auth.py b/synapse/api/auth.py
index 59852bdbdb..cb50579fd2 100644
--- a/synapse/api/auth.py
+++ b/synapse/api/auth.py
@@ -211,6 +211,7 @@ class Auth(object):
             if user_id:
                 request.authenticated_entity = user_id
                 opentracing.set_tag("authenticated_entity", user_id)
+                opentracing.set_tag("appservice_id", app_service.id)
 
                 if ip_addr and self.hs.config.track_appservice_user_ips:
                     yield self.store.insert_client_ip(
@@ -262,6 +263,8 @@ class Auth(object):
 
             request.authenticated_entity = user.to_string()
             opentracing.set_tag("authenticated_entity", user.to_string())
+            if device_id:
+                opentracing.set_tag("device_id", device_id)
 
             return synapse.types.create_requester(
                 user, token_id, is_guest, device_id, app_service=app_service