BG_JOB_STATE enumeration

The BG_JOB_STATE enumeration defines constant values for the different states of a job.

Syntax

typedef enum  { 
  BG_JOB_STATE_QUEUED,
  BG_JOB_STATE_CONNECTING,
  BG_JOB_STATE_TRANSFERRING,
  BG_JOB_STATE_SUSPENDED,
  BG_JOB_STATE_ERROR,
  BG_JOB_STATE_TRANSIENT_ERROR,
  BG_JOB_STATE_TRANSFERRED,
  BG_JOB_STATE_ACKNOWLEDGED,
  BG_JOB_STATE_CANCELLED
} BG_JOB_STATE;

Constants

BG_JOB_STATE_QUEUED

Specifies that the job is in the queue and waiting to run. If a user logs off while their job is transferring, the job transitions to the queued state.

BG_JOB_STATE_CONNECTING

Not supported.

BG_JOB_STATE_TRANSFERRING

Specifies that Delivery Optimization is transferring data for the job.

BG_JOB_STATE_SUSPENDED

Specifies that the job is suspended (paused). To suspend a job, call the IBackgroundCopyJob::Suspend method. The job remains suspended until you call the IBackgroundCopyJob::Resume, IBackgroundCopyJob::Complete, or IBackgroundCopyJob::Cancel method.

BG_JOB_STATE_ERROR

Specifies that a nonrecoverable error occurred (the service is unable to transfer the file). If the error, such as an access-denied error, can be corrected, call the IBackgroundCopyJob::Resume method after the error is fixed. However, if the error cannot be corrected, call the IBackgroundCopyJob::Cancel method to cancel the job, or call the IBackgroundCopyJob::Complete method to accept the portion of a download job that transferred successfully.

BG_JOB_STATE_TRANSIENT_ERROR

Specifies that a recoverable error occurred. Delivery Optimization will retry jobs in the transient error state based on the internal retry configuration. The state of the job changes to BG_JOB_STATE_ERROR if the job fails to make progress (see IBackgroundCopyJob::SetNoProgressTimeout).

BG_JOB_STATE_TRANSFERRED

Specifies that your job was successfully processed. You must call the IBackgroundCopyJob::Complete method to acknowledge completion of the job and to make the files available to the client.

BG_JOB_STATE_ACKNOWLEDGED

Specifies that you called the IBackgroundCopyJob::Complete method to acknowledge that your job completed successfully.

BG_JOB_STATE_CANCELLED

Specifies that you called the IBackgroundCopyJob::Cancel method to cancel the job (remove the job from the transfer queue).

Requirements

Requirement Value
Minimum supported client
Windows 10, version 1709 [desktop apps only]
Minimum supported server
Windows Server, version 1709 [desktop apps only]
Header
Deliveryoptimization.h

See also

IBackgroundCopyJob::GetState