Compartilhar via


JobProperties Class

  • java.lang.Object
    • com.microsoft.azure.sdk.iot.service.JobProperties

public class JobProperties

Contains properties of a Job. See online documentation for more infomration.

Constructor Summary

Constructor Description
JobProperties()

Method Summary

Modifier and Type Method and Description
static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport)

Creates an instance of JobProperties with parameters ready to start an Export job

static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport, StorageAuthenticationType storageAuthenticationType)

Creates an instance of JobProperties with parameters ready to start an Export job

static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport, StorageAuthenticationType storageAuthenticationType, ManagedIdentity identity)

Creates an instance of JobProperties with parameters ready to start an Export job

static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri)

Creates an instance of JobProperties with parameters ready to start an Import job

static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri, StorageAuthenticationType storageAuthenticationType)

Creates an instance of JobProperties with parameters ready to start an Import job

static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri, StorageAuthenticationType storageAuthenticationType, ManagedIdentity identity)

Creates an instance of JobProperties with parameters ready to start an Import job

java.util.Date getEndTimeUtc()
boolean getExcludeKeysInExport()
java.lang.String getFailureReason()
ManagedIdentity getIdentity()
java.lang.String getInputBlobContainerUri()
java.lang.String getJobId()
java.lang.String getOutputBlobContainerUri()
int getProgress()
java.util.Date getStartTimeUtc()
JobStatus getStatus()
StorageAuthenticationType getStorageAuthenticationType()
JobType getType()
void setEndTimeUtc(Date endTimeUtc)
void setExcludeKeysInExport(boolean excludeKeysInExport)
void setFailureReason(String failureReason)
void setIdentity(ManagedIdentity identity)
void setInputBlobContainerUri(String inputBlobContainerUri)
void setJobId(String jobId)
final void setJobIdFinal(String jobId)
void setOutputBlobContainerUri(String outputBlobContainerUri)
void setProgress(int progress)
void setStartTimeUtc(Date startTimeUtc)
void setStatus(JobProperties.JobStatus status)
void setStorageAuthenticationType(StorageAuthenticationType storageAuthenticationType)
void setType(JobProperties.JobType type)

Methods inherited from java.lang.Object

java.lang.Object.clone java.lang.Object.equals java.lang.Object.finalize java.lang.Object.getClass java.lang.Object.hashCode java.lang.Object.notify java.lang.Object.notifyAll java.lang.Object.toString java.lang.Object.wait java.lang.Object.wait java.lang.Object.wait

Constructor Details

JobProperties

public JobProperties()

Method Details

createForExportJob

public static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport)

Creates an instance of JobProperties with parameters ready to start an Export job

Parameters:

outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType
excludeKeysInExport - Indicates if authorization keys are included in export output

Returns:

An instance of JobProperties

createForExportJob

public static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport, StorageAuthenticationType storageAuthenticationType)

Creates an instance of JobProperties with parameters ready to start an Export job

Parameters:

outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType
excludeKeysInExport - Indicates if authorization keys are included in export output
storageAuthenticationType - Specifies authentication type being used for connecting to storage account

Returns:

An instance of JobProperties

createForExportJob

public static JobProperties createForExportJob(String outputBlobContainerUri, Boolean excludeKeysInExport, StorageAuthenticationType storageAuthenticationType, ManagedIdentity identity)

Creates an instance of JobProperties with parameters ready to start an Export job

Parameters:

outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType
excludeKeysInExport - Indicates if authorization keys are included in export output
storageAuthenticationType - Specifies authentication type being used for connecting to storage account
identity - the managed identity used to access the storage account for export jobs.

Returns:

An instance of JobProperties

createForImportJob

public static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri)

Creates an instance of JobProperties with parameters ready to start an Import job

Parameters:

inputBlobContainerUri - URI to a blob container that contains registry data to sync. Including a SAS token is dependent on the StorageAuthenticationType
outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType

Returns:

An instance of JobProperties

createForImportJob

public static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri, StorageAuthenticationType storageAuthenticationType)

Creates an instance of JobProperties with parameters ready to start an Import job

Parameters:

inputBlobContainerUri - URI to a blob container that contains registry data to sync. Including a SAS token is dependent on the StorageAuthenticationType
outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType
storageAuthenticationType - Specifies authentication type being used for connecting to storage account

Returns:

An instance of JobProperties

createForImportJob

public static JobProperties createForImportJob(String inputBlobContainerUri, String outputBlobContainerUri, StorageAuthenticationType storageAuthenticationType, ManagedIdentity identity)

Creates an instance of JobProperties with parameters ready to start an Import job

Parameters:

inputBlobContainerUri - URI to a blob container that contains registry data to sync. Including a SAS token is dependent on the StorageAuthenticationType
outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType
storageAuthenticationType - Specifies authentication type being used for connecting to storage account
identity - the managed identity used to access the storage account for import jobs.

Returns:

An instance of JobProperties

getEndTimeUtc

public Date getEndTimeUtc()

Returns:

the UTC job end time. Ignored at creation. Represents the time the job stopped processing.

getExcludeKeysInExport

public boolean getExcludeKeysInExport()

Returns:

whether the keys are included in export or not.

getFailureReason

public String getFailureReason()

Returns:

System generated. Ignored at creation. If status == failure, this represents a string containing the reason.

getIdentity

public ManagedIdentity getIdentity()

Returns:

The managed identity used to access the storage account for import and export jobs.

getInputBlobContainerUri

public String getInputBlobContainerUri()

Returns:

URI to a blob container that contains registry data to sync. Including a SAS token is dependent on the StorageAuthenticationType

getJobId

public String getJobId()

Returns:

the system generated job id. Ignored at creation.

getOutputBlobContainerUri

public String getOutputBlobContainerUri()

Returns:

URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType

getProgress

public int getProgress()

Returns:

the system generated job progress. Ignored at creation. Represents the completion percentage.

getStartTimeUtc

public Date getStartTimeUtc()

Returns:

the system generated UTC job start time. Ignored at creation.

getStatus

public JobProperties.JobStatus getStatus()

Returns:

the system generated job status. Ignored at creation.

getStorageAuthenticationType

public StorageAuthenticationType getStorageAuthenticationType()

Returns:

authentication type being used for connecting to storage account

getType

public JobProperties.JobType getType()

Returns:

the type of job to execute.

setEndTimeUtc

public void setEndTimeUtc(Date endTimeUtc)

Parameters:

endTimeUtc - the UTC job end time.

setExcludeKeysInExport

public void setExcludeKeysInExport(boolean excludeKeysInExport)

Parameters:

excludeKeysInExport - optional for export jobs; ignored for other jobs. Default: false. If false, authorization keys are included in export output. Keys are exported as null otherwise.

setFailureReason

public void setFailureReason(String failureReason)

Parameters:

failureReason - the failure reason.

setIdentity

public void setIdentity(ManagedIdentity identity)

Parameters:

identity - The managed identity used to access the storage account for import and export jobs.

setInputBlobContainerUri

public void setInputBlobContainerUri(String inputBlobContainerUri)

Parameters:

inputBlobContainerUri - URI to a blob container that contains registry data to sync. Including a SAS token is dependent on the StorageAuthenticationType

setJobId


public void setJobId(String jobId)

Parameters:

jobId - the job id

Throws:

java.lang.IllegalArgumentException - if the provided jobId is null

setJobIdFinal

public final void setJobIdFinal(String jobId)

Parameters:

jobId - the job id

Throws:

java.lang.IllegalArgumentException - if the provided jobId is null

setOutputBlobContainerUri

public void setOutputBlobContainerUri(String outputBlobContainerUri)

Parameters:

outputBlobContainerUri - URI to a blob container. This is used to output the status of the job and the results. Including a SAS token is dependent on the StorageAuthenticationType

setProgress

public void setProgress(int progress)

Parameters:

progress - the job progress.

setStartTimeUtc

public void setStartTimeUtc(Date startTimeUtc)

Parameters:

startTimeUtc - the UTC job start time.

setStatus

public void setStatus(JobProperties.JobStatus status)

Parameters:

status - the job status.

setStorageAuthenticationType

public void setStorageAuthenticationType(StorageAuthenticationType storageAuthenticationType)

Parameters:

storageAuthenticationType - Specifies authentication type being used for connecting to storage account

setType

public void setType(JobProperties.JobType type)

Parameters:

type - the type of job to execute.

Applies to