Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
S
Scheduler
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Antoine R. Dumont
Scheduler
Commits
bed3529a
Unverified
Commit
bed3529a
authored
5 months ago
by
Antoine R. Dumont
Browse files
Options
Downloads
Patches
Plain Diff
scheduler/runner-first-visits: Log number of first visits scheduled
Refs.
swh/devel/swh-scheduler#4687
parent
72f72130
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
swh/scheduler/celery_backend/first_visits.py
+3
-1
3 additions, 1 deletion
swh/scheduler/celery_backend/first_visits.py
swh/scheduler/cli/admin.py
+3
-2
3 additions, 2 deletions
swh/scheduler/cli/admin.py
with
6 additions
and
3 deletions
swh/scheduler/celery_backend/first_visits.py
+
3
−
1
View file @
bed3529a
...
...
@@ -40,7 +40,7 @@ def schedule_first_visits(backend: SchedulerInterface):
f
"
{
lister
.
first_visits_queue_prefix
}
:
{
task_type
.
backend_name
}
"
)
send_to_celery
(
nb_first_visits
=
send_to_celery
(
backend
,
visit_type_to_queue
=
visit_type_to_queue
,
policy
=
"
first_visits_after_listing
"
,
...
...
@@ -84,3 +84,5 @@ def schedule_first_visits(backend: SchedulerInterface):
)
lister
.
first_visits_scheduled_at
=
utcnow
()
backend
.
update_lister
(
lister
)
return
nb_first_visits
This diff is collapsed.
Click to expand it.
swh/scheduler/cli/admin.py
+
3
−
2
View file @
bed3529a
...
...
@@ -248,9 +248,10 @@ def runner_first_visits(ctx, period):
try
:
while
True
:
logger
.
debug
(
"
Schedule first visits
"
)
logger
.
debug
(
"
Schedule first visits
...
"
)
try
:
schedule_first_visits
(
scheduler
)
nb_first_visits
=
schedule_first_visits
(
scheduler
)
logger
.
info
(
"
Scheduled %s first visits
"
,
nb_first_visits
)
except
ValueError
:
logger
.
exception
(
"
Unexpected error in run_high_priority_first_visits()
"
)
sentry_sdk
.
capture_exception
()
...
...
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