https://pulp.plan.io/https://pulp.plan.io/favicon.ico2018-07-30T18:34:40ZPulpPulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=297472018-07-30T18:34:40Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/29747/diff?detail_id=30419">diff</a>)</li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=297512018-07-31T08:30:26Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/29751/diff?detail_id=30422">diff</a>)</li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=297552018-07-31T13:57:23Zttereshcttereshc@redhat.com
<ul></ul><p>Numbers to show impact: <a href="https://bugzilla.redhat.com/show_bug.cgi?id=1609928#c5" class="external">https://bugzilla.redhat.com/show_bug.cgi?id=1609928#c5</a></p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=297642018-07-31T14:45:10ZCodeHeeler
<ul><li><strong>Priority</strong> changed from <i>Normal</i> to <i>High</i></li><li><strong>Severity</strong> changed from <i>2. Medium</i> to <i>3. High</i></li><li><strong>Triaged</strong> changed from <i>No</i> to <i>Yes</i></li><li><strong>Sprint</strong> set to <i>Sprint 40</i></li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=298102018-08-02T14:37:12Zttereshcttereshc@redhat.com
<ul></ul><p>Cron configuration to make this task run regularly is enough to fix this task.<br>
The suggestion is to put it into /etc/cron.monthly and ship this config with rpm installation.</p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=298132018-08-02T15:03:28Zbmbouterbmbouter@redhat.com
<ul></ul><p><a class="user active" href="https://pulp.plan.io/users/281">ttereshc</a> excellent! Also remove this part of the code with that change too: <a href="https://github.com/pulp/pulp/blob/2-master/server/pulp/server/async/celery_instance.py#L30-L33" class="external">https://github.com/pulp/pulp/blob/2-master/server/pulp/server/async/celery_instance.py#L30-L33</a></p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=298192018-08-02T15:21:28Zbmbouterbmbouter@redhat.com
<ul><li><strong>Status</strong> changed from <i>NEW</i> to <i>ASSIGNED</i></li><li><strong>Assignee</strong> set to <i>bmbouter</i></li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=298862018-08-06T13:17:05Zrchan
<ul><li><strong>Sprint</strong> changed from <i>Sprint 40</i> to <i>Sprint 41</i></li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=300332018-08-07T16:51:06Zbmbouterbmbouter@redhat.com
<ul></ul><p>This is working for me. I have the latest branch head of pulp/pulp:2-master and pulp/pulp_rpm:2-master. I applied the following diff to test it:</p>
<pre><code class="diff syntaxhl" data-language="diff"><span class="gh">diff --git a/server/pulp/server/async/celery_instance.py b/server/pulp/server/async/celery_instance.py
index eab2ea3dd..9b486e8a5 100644
</span><span class="gd">--- a/server/pulp/server/async/celery_instance.py
</span><span class="gi">+++ b/server/pulp/server/async/celery_instance.py
</span><span class="p">@@ -29,7 +29,7 @@</span> CELERYBEAT_SCHEDULE = {
},
'monthly_maintenance': {
'task': 'pulp.server.maintenance.monthly.queue_monthly_maintenance',
<span class="gd">- 'schedule': timedelta(days=30),
</span><span class="gi">+ 'schedule': timedelta(seconds=60),
</span> 'args': tuple(),
},
'download_deferred_content': {
<span class="gh">diff --git a/server/pulp/server/maintenance/monthly.py b/server/pulp/server/maintenance/monthly.py
index 58e51f247..365496ea0 100644
</span><span class="gd">--- a/server/pulp/server/maintenance/monthly.py
</span><span class="gi">+++ b/server/pulp/server/maintenance/monthly.py
</span><span class="p">@@ -10,6 +10,7 @@</span> def queue_monthly_maintenance():
"""
Create an itinerary for monthly task
"""
<span class="gi">+ raise Exception('oh no!')
</span> tags = [action_tag('monthly')]
monthly_maintenance.apply_async(tags=tags)
</code></pre>
<p>Then I got the following output upon startup:</p>
<pre><code>kombu.transport.qpid:INFO: Connected to qpid with SASL mechanism ANONYMOUS
celery.beat:INFO: Scheduler: Sending due task monthly_maintenance (pulp.server.maintenance.monthly.queue_monthly_maintenance)
celery.worker.strategy:INFO: Received task: pulp.server.maintenance.monthly.queue_monthly_maintenance[e465c5d5-4385-4dcb-89ff-24013669c252]
celery.app.trace:ERROR: [e465c5d5] (18124-49472) Task pulp.server.maintenance.monthly.queue_monthly_maintenance[e465c5d5-4385-4dcb-89ff-24013669c252] raised unexpected: Exception('oh no!',)
celery.app.trace:ERROR: [e465c5d5] (18124-49472) Traceback (most recent call last):
celery.app.trace:ERROR: [e465c5d5] (18124-49472) File "/usr/lib/python2.7/site-packages/celery/app/trace.py", line 367, in trace_task
celery.app.trace:ERROR: [e465c5d5] (18124-49472) R = retval = fun(*args, **kwargs)
celery.app.trace:ERROR: [e465c5d5] (18124-49472) File "/home/vagrant/devel/pulp/server/pulp/server/async/tasks.py", line 107, in __call__
celery.app.trace:ERROR: [e465c5d5] (18124-49472) return super(PulpTask, self).__call__(*args, **kwargs)
celery.app.trace:ERROR: [e465c5d5] (18124-49472) File "/usr/lib/python2.7/site-packages/celery/app/trace.py", line 622, in __protected_call__
celery.app.trace:ERROR: [e465c5d5] (18124-49472) return self.run(*args, **kwargs)
celery.app.trace:ERROR: [e465c5d5] (18124-49472) File "/home/vagrant/devel/pulp/server/pulp/server/maintenance/monthly.py", line 13, in queue_monthly_maintenance
celery.app.trace:ERROR: [e465c5d5] (18124-49472) raise Exception('oh no!')
celery.app.trace:ERROR: [e465c5d5] (18124-49472) Exception: oh no!
</code></pre>
<p>I am using Celery 4.0.2-3 with <code>python2-celery-4.0.2-3.fc27.noarch</code>.</p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=300662018-08-08T20:11:45Zbmbouterbmbouter@redhat.com
<ul><li><strong>Subject</strong> changed from <i> Periodic task pulp.server.maintenance.monthly doesn't seem to get scheduled</i> to <i>Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduled</i></li><li><strong>Description</strong> updated (<a title="View differences" href="/journals/30066/diff?detail_id=30781">diff</a>)</li><li><strong>Tags</strong> <i>Documentation</i> added</li></ul><p>Rewriting based on root cause discovery. This will become a docs bug explaining the recommended workaround.</p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=300672018-08-08T20:38:08Zbmbouterbmbouter@redhat.com
<ul><li><strong>Status</strong> changed from <i>ASSIGNED</i> to <i>POST</i></li></ul><p>docs PR available at: <a href="https://github.com/pulp/pulp/pull/3585" class="external">https://github.com/pulp/pulp/pull/3585</a></p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=300682018-08-08T21:06:37Zbmbouterbmbouter@redhat.com
<ul><li><strong>Status</strong> changed from <i>POST</i> to <i>MODIFIED</i></li></ul><p>Applied in changeset <a class="changeset" title="Add docs on maintenance jobs This adds: * An extra configuration section * A troubleshooting sec..." href="https://pulp.plan.io/projects/pulp/repository/pulp/revisions/97331ca0c398ff6371b03982260a3776a8d8ac80">pulp|97331ca0c398ff6371b03982260a3776a8d8ac80</a>.</p> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=300862018-08-10T14:03:09Zbmbouterbmbouter@redhat.com
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-11 priority-6 priority-default closed" href="/issues/3908">Issue #3908</a>: Add pulp-maintenance package </i> added</li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=309332018-09-18T18:02:25Zdkliban@redhat.com
<ul><li><strong>Status</strong> changed from <i>MODIFIED</i> to <i>CLOSED - CURRENTRELEASE</i></li><li><strong>Platform Release</strong> set to <i>2.17.0</i></li></ul> Pulp - Issue #3887: Restarting pulp_celerybeat weekly or so causes pulp.server.maintenance.monthly to not get scheduledhttps://pulp.plan.io/issues/3887?journal_id=377992019-04-15T20:09:41Zbmbouterbmbouter@redhat.com
<ul><li><strong>Tags</strong> <i>Pulp 2</i> added</li></ul>