Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
synapse
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Maunium
synapse
Commits
05bae6b4
Commit
05bae6b4
authored
5 years ago
by
Erik Johnston
Browse files
Options
Downloads
Patches
Plain Diff
Add opentracing span for HTTP push
parent
55d5b3af
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
synapse/push/httppusher.py
+12
-1
12 additions, 1 deletion
synapse/push/httppusher.py
with
12 additions
and
1 deletion
synapse/push/httppusher.py
+
12
−
1
View file @
05bae6b4
...
@@ -22,6 +22,7 @@ from prometheus_client import Counter
...
@@ -22,6 +22,7 @@ from prometheus_client import Counter
from
twisted.internet
import
defer
from
twisted.internet
import
defer
from
twisted.internet.error
import
AlreadyCalled
,
AlreadyCancelled
from
twisted.internet.error
import
AlreadyCalled
,
AlreadyCancelled
from
synapse.logging
import
opentracing
from
synapse.metrics.background_process_metrics
import
run_as_background_process
from
synapse.metrics.background_process_metrics
import
run_as_background_process
from
synapse.push
import
PusherConfigException
from
synapse.push
import
PusherConfigException
...
@@ -194,7 +195,17 @@ class HttpPusher(object):
...
@@ -194,7 +195,17 @@ class HttpPusher(object):
)
)
for
push_action
in
unprocessed
:
for
push_action
in
unprocessed
:
processed
=
yield
self
.
_process_one
(
push_action
)
with
opentracing
.
start_active_span
(
"
http-push
"
,
tags
=
{
"
authenticated_entity
"
:
self
.
user_id
,
"
event_id
"
:
push_action
[
"
event_id
"
],
"
app_id
"
:
self
.
app_id
,
"
app_display_name
"
:
self
.
app_display_name
,
},
):
processed
=
yield
self
.
_process_one
(
push_action
)
if
processed
:
if
processed
:
http_push_processed_counter
.
inc
()
http_push_processed_counter
.
inc
()
self
.
backoff_delay
=
HttpPusher
.
INITIAL_BACKOFF_SEC
self
.
backoff_delay
=
HttpPusher
.
INITIAL_BACKOFF_SEC
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment