Closed Bug 1572509 Opened 6 years ago Closed 6 years ago

PingUploadWorker may get stuck in infinite loop if upload disabled.

Categories

(Data Platform and Tools :: Glean: SDK, defect, P1)

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: travis_, Assigned: travis_)

Details

(Whiteboard: [telemetry:glean-rs:m8][telemetry:mobilesdk:m8])

Attachments

(2 files)

The current ping upload worker is checking the success of the uploadPings() function to determine if it reports that the worker needs to retry():

    override fun doWork(): Result {
        if (!uploadPings()) {
            return Result.retry()
        }

        return Result.success()
    }

This is a problem because the uploadPings() function returns false if getUploadEnabled() is false, creating a situation where the worker would continue to run, and retry when upload is disabled.

Attached file GitHub Pull Request

PR for glean-ac

Attached file GitHub Pull Request

PR for glean-rs

Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: