Page MenuHomePhabricator

Tasks should clean up after themselves when they fail in STARTING phase
Closed, DeclinedPublic

Description

Tasks should clean up after themselves when SoftTimeLimitExceeded exception is raised.

If not a report (=task) will appear on the database with status STARTED when in fact will never complete, as it was cancelled (for taking too much time)

This is happening right now with PagesCreated and NamespaceCreated for enwiki

17911172014-10-21 00:00:00enwiki - PagesCreatedSTARTED
17911222014-10-22 00:00:00enwiki - PagesCreatedSTARTED

In the code we are handling properly reports left in stage "PENDING" but not started (which indicate that report could not even start really)


Version: unspecified
Severity: normal

Details

Reference
bz72563

Related Objects

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:53 AM
bzimport set Reference to bz72563.
bzimport added a subscriber: Unknown Object (MLST).

Tasks should clean up after themselves when SoftTimeLimitExceeded exception is raised.

Taking this back, this is already happening. Now, what is missing is exceptions raised
within the STARTING or PENDING phase that are not related to tasks taking too long.

Any exception should mark task as "FAILURE" so a future run of the scheduler (if recurrent) can pick it up.

We likely need to catch all db errors via catching the highest level exception on sqlalchemy exception classes at the same level where we are catching now SoftTimeLimitExceeded

Declining because Wikimetrics is being discontinued. See: T211835.