ApiReplicationSchedule Data Model

A replication job schedule.

Replication jobs have service-specific arguments. This object has methods to retrieve arguments for all supported types of replication, but only one argument type is allowed to be set; the backend will check that the provided argument matches the service type where the replication is being scheduled.

The replication job's arguments should match the underlying service. Refer to each property's documentation to find out which properties correspond to which services.

Properties
name data type description
hdfsArguments ApiHdfsReplicationArguments Arguments for HDFS replication commands.
hiveArguments ApiHiveReplicationArguments Arguments for Hive replication commands.
hdfsCloudArguments ApiHdfsCloudReplicationArguments Arguments for HDFS cloud replication commands.
history array of ApiReplicationCommand List of active and/or finished commands for this schedule.
active boolean Read-only field that is true if this schedule is currently active, false if not. Available since API v11.
hiveCloudArguments ApiHiveCloudReplicationArguments Arguments for Hive cloud replication commands.
Properties inherited from ApiSchedule
id number The schedule id.
displayName string The schedule display name.
description string The schedule description.
startTime string The time at which the scheduled activity is triggered for the first time.
endTime string The time after which the scheduled activity will no longer be triggered.
interval number The duration between consecutive triggers of a scheduled activity.
intervalUnit ApiScheduleInterval The unit for the repeat interval.
nextRun string Readonly. The time the scheduled command will run next.
paused boolean The paused state for the schedule. The scheduled activity will not be triggered as long as the scheduled is paused.
alertOnStart boolean Whether to alert on start of the scheduled activity.
alertOnSuccess boolean Whether to alert on successful completion of the scheduled activity.
alertOnFail boolean Whether to alert on failure of the scheduled activity.
alertOnAbort boolean Whether to alert on abort of the scheduled activity.

Example

{
  "hdfsArguments" : {
    "sourceService" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "sourcePath" : "...",
    "destinationPath" : "...",
    "mapreduceServiceName" : "...",
    "schedulerPoolName" : "...",
    "userName" : "...",
    "sourceUser" : "...",
    "numMaps" : 12345,
    "dryRun" : true,
    "bandwidthPerMap" : 12345,
    "abortOnError" : true,
    "removeMissingFiles" : true,
    "preserveReplicationCount" : true,
    "preserveBlockSize" : true,
    "preservePermissions" : true,
    "logPath" : "...",
    "skipChecksumChecks" : true,
    "skipListingChecksumChecks" : true,
    "skipTrash" : true,
    "replicationStrategy" : "DYNAMIC",
    "preserveXAttrs" : true,
    "exclusionFilters" : [ "...", "..." ],
    "raiseSnapshotDiffFailures" : true,
    "destinationCloudAccount" : "..."
  },
  "hiveArguments" : {
    "sourceService" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "tableFilters" : [ {
      "database" : "...",
      "tableName" : "..."
    }, {
      "database" : "...",
      "tableName" : "..."
    } ],
    "exportDir" : "...",
    "force" : true,
    "replicateData" : true,
    "hdfsArguments" : {
      "sourceService" : { },
      "sourcePath" : "...",
      "destinationPath" : "...",
      "mapreduceServiceName" : "...",
      "schedulerPoolName" : "...",
      "userName" : "...",
      "sourceUser" : "...",
      "numMaps" : 12345,
      "dryRun" : true,
      "bandwidthPerMap" : 12345,
      "abortOnError" : true,
      "removeMissingFiles" : true,
      "preserveReplicationCount" : true,
      "preserveBlockSize" : true,
      "preservePermissions" : true,
      "logPath" : "...",
      "skipChecksumChecks" : true,
      "skipListingChecksumChecks" : true,
      "skipTrash" : true,
      "replicationStrategy" : "STATIC",
      "preserveXAttrs" : true,
      "exclusionFilters" : [ "...", "..." ],
      "raiseSnapshotDiffFailures" : true,
      "destinationCloudAccount" : "..."
    },
    "replicateImpalaMetadata" : true,
    "runInvalidateMetadata" : true,
    "dryRun" : true,
    "numThreads" : 12345
  },
  "hdfsCloudArguments" : {
    "sourceAccount" : "...",
    "destinationAccount" : "...",
    "sourceService" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "sourcePath" : "...",
    "destinationPath" : "...",
    "mapreduceServiceName" : "...",
    "schedulerPoolName" : "...",
    "userName" : "...",
    "sourceUser" : "...",
    "numMaps" : 12345,
    "dryRun" : true,
    "bandwidthPerMap" : 12345,
    "abortOnError" : true,
    "removeMissingFiles" : true,
    "preserveReplicationCount" : true,
    "preserveBlockSize" : true,
    "preservePermissions" : true,
    "logPath" : "...",
    "skipChecksumChecks" : true,
    "skipListingChecksumChecks" : true,
    "skipTrash" : true,
    "replicationStrategy" : "DYNAMIC",
    "preserveXAttrs" : true,
    "exclusionFilters" : [ "...", "..." ],
    "raiseSnapshotDiffFailures" : true,
    "destinationCloudAccount" : "..."
  },
  "history" : [ {
    "hdfsResult" : {
      "progress" : 12345,
      "throughput" : 12345.0,
      "remainingTime" : 12345,
      "estimatedCompletionTime" : "...",
      "counters" : [ { }, { } ],
      "numFilesDryRun" : 12345,
      "numBytesDryRun" : 12345,
      "numFilesExpected" : 12345,
      "numBytesExpected" : 12345,
      "numFilesCopied" : 12345,
      "numBytesCopied" : 12345,
      "numFilesSkipped" : 12345,
      "numBytesSkipped" : 12345,
      "numFilesDeleted" : 12345,
      "numFilesCopyFailed" : 12345,
      "numBytesCopyFailed" : 12345,
      "setupError" : "...",
      "jobId" : "...",
      "jobDetailsUri" : "...",
      "dryRun" : true,
      "snapshottedDirs" : [ "...", "..." ],
      "runAsUser" : "...",
      "runOnSourceAsUser" : "...",
      "logPath" : "...",
      "failedFiles" : [ "...", "..." ]
    },
    "hiveResult" : {
      "phase" : "...",
      "tableCount" : 12345,
      "tables" : [ { }, { } ],
      "impalaUDFCount" : 12345,
      "hiveUDFCount" : 12345,
      "impalaUDFs" : [ { }, { } ],
      "hiveUDFs" : [ { }, { } ],
      "errorCount" : 12345,
      "errors" : [ { }, { } ],
      "dataReplicationResult" : { },
      "dryRun" : true,
      "runAsUser" : "...",
      "runOnSourceAsUser" : "...",
      "logPath" : "...",
      "directoryForMetadata" : "...",
      "statsAvailable" : true,
      "dbProcessed" : 12345,
      "tableProcessed" : 12345,
      "partitionProcessed" : 12345,
      "functionProcessed" : 12345,
      "indexProcessed" : 12345,
      "statsProcessed" : 12345,
      "dbExpected" : 12345,
      "tableExpected" : 12345,
      "partitionExpected" : 12345,
      "functionExpected" : 12345,
      "indexExpected" : 12345,
      "statsExpected" : 12345
    },
    "id" : 12345,
    "name" : "...",
    "startTime" : "...",
    "endTime" : "...",
    "active" : true,
    "success" : true,
    "resultMessage" : "...",
    "resultDataUrl" : "...",
    "clusterRef" : {
      "clusterName" : "...",
      "displayName" : "..."
    },
    "serviceRef" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "roleRef" : {
      "clusterName" : "...",
      "serviceName" : "...",
      "roleName" : "..."
    },
    "hostRef" : {
      "hostId" : "...",
      "hostname" : "..."
    },
    "parent" : {
      "id" : 12345,
      "name" : "...",
      "startTime" : "...",
      "endTime" : "...",
      "active" : true,
      "success" : true,
      "resultMessage" : "...",
      "resultDataUrl" : "...",
      "clusterRef" : { },
      "serviceRef" : { },
      "roleRef" : { },
      "hostRef" : { },
      "parent" : { },
      "children" : { },
      "canRetry" : true
    },
    "children" : {
      "items" : [ { }, { } ]
    },
    "canRetry" : true
  }, {
    "hdfsResult" : {
      "progress" : 12345,
      "throughput" : 12345.0,
      "remainingTime" : 12345,
      "estimatedCompletionTime" : "...",
      "counters" : [ { }, { } ],
      "numFilesDryRun" : 12345,
      "numBytesDryRun" : 12345,
      "numFilesExpected" : 12345,
      "numBytesExpected" : 12345,
      "numFilesCopied" : 12345,
      "numBytesCopied" : 12345,
      "numFilesSkipped" : 12345,
      "numBytesSkipped" : 12345,
      "numFilesDeleted" : 12345,
      "numFilesCopyFailed" : 12345,
      "numBytesCopyFailed" : 12345,
      "setupError" : "...",
      "jobId" : "...",
      "jobDetailsUri" : "...",
      "dryRun" : true,
      "snapshottedDirs" : [ "...", "..." ],
      "runAsUser" : "...",
      "runOnSourceAsUser" : "...",
      "logPath" : "...",
      "failedFiles" : [ "...", "..." ]
    },
    "hiveResult" : {
      "phase" : "...",
      "tableCount" : 12345,
      "tables" : [ { }, { } ],
      "impalaUDFCount" : 12345,
      "hiveUDFCount" : 12345,
      "impalaUDFs" : [ { }, { } ],
      "hiveUDFs" : [ { }, { } ],
      "errorCount" : 12345,
      "errors" : [ { }, { } ],
      "dataReplicationResult" : { },
      "dryRun" : true,
      "runAsUser" : "...",
      "runOnSourceAsUser" : "...",
      "logPath" : "...",
      "directoryForMetadata" : "...",
      "statsAvailable" : true,
      "dbProcessed" : 12345,
      "tableProcessed" : 12345,
      "partitionProcessed" : 12345,
      "functionProcessed" : 12345,
      "indexProcessed" : 12345,
      "statsProcessed" : 12345,
      "dbExpected" : 12345,
      "tableExpected" : 12345,
      "partitionExpected" : 12345,
      "functionExpected" : 12345,
      "indexExpected" : 12345,
      "statsExpected" : 12345
    },
    "id" : 12345,
    "name" : "...",
    "startTime" : "...",
    "endTime" : "...",
    "active" : true,
    "success" : true,
    "resultMessage" : "...",
    "resultDataUrl" : "...",
    "clusterRef" : {
      "clusterName" : "...",
      "displayName" : "..."
    },
    "serviceRef" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "roleRef" : {
      "clusterName" : "...",
      "serviceName" : "...",
      "roleName" : "..."
    },
    "hostRef" : {
      "hostId" : "...",
      "hostname" : "..."
    },
    "parent" : {
      "id" : 12345,
      "name" : "...",
      "startTime" : "...",
      "endTime" : "...",
      "active" : true,
      "success" : true,
      "resultMessage" : "...",
      "resultDataUrl" : "...",
      "clusterRef" : { },
      "serviceRef" : { },
      "roleRef" : { },
      "hostRef" : { },
      "parent" : { },
      "children" : { },
      "canRetry" : true
    },
    "children" : {
      "items" : [ { }, { } ]
    },
    "canRetry" : true
  } ],
  "active" : true,
  "hiveCloudArguments" : {
    "sourceAccount" : "...",
    "destinationAccount" : "...",
    "cloudRootPath" : "...",
    "replicationOption" : "KEEP_DATA_IN_CLOUD",
    "sentryMigration" : true,
    "sourceService" : {
      "peerName" : "...",
      "clusterName" : "...",
      "serviceName" : "...",
      "serviceDisplayName" : "...",
      "serviceType" : "..."
    },
    "tableFilters" : [ {
      "database" : "...",
      "tableName" : "..."
    }, {
      "database" : "...",
      "tableName" : "..."
    } ],
    "exportDir" : "...",
    "force" : true,
    "replicateData" : true,
    "hdfsArguments" : {
      "sourceService" : { },
      "sourcePath" : "...",
      "destinationPath" : "...",
      "mapreduceServiceName" : "...",
      "schedulerPoolName" : "...",
      "userName" : "...",
      "sourceUser" : "...",
      "numMaps" : 12345,
      "dryRun" : true,
      "bandwidthPerMap" : 12345,
      "abortOnError" : true,
      "removeMissingFiles" : true,
      "preserveReplicationCount" : true,
      "preserveBlockSize" : true,
      "preservePermissions" : true,
      "logPath" : "...",
      "skipChecksumChecks" : true,
      "skipListingChecksumChecks" : true,
      "skipTrash" : true,
      "replicationStrategy" : "STATIC",
      "preserveXAttrs" : true,
      "exclusionFilters" : [ "...", "..." ],
      "raiseSnapshotDiffFailures" : true,
      "destinationCloudAccount" : "..."
    },
    "replicateImpalaMetadata" : true,
    "runInvalidateMetadata" : true,
    "dryRun" : true,
    "numThreads" : 12345
  },
  "id" : 12345,
  "displayName" : "...",
  "description" : "...",
  "startTime" : "...",
  "endTime" : "...",
  "interval" : 12345,
  "intervalUnit" : "YEAR",
  "nextRun" : "...",
  "paused" : true,
  "alertOnStart" : true,
  "alertOnSuccess" : true,
  "alertOnFail" : true,
  "alertOnAbort" : true
}