Class: OCI::DataCatalog::Models::JobSummary
- Inherits:
-
Object
- Object
- OCI::DataCatalog::Models::JobSummary
- Defined in:
- lib/oci/data_catalog/models/job_summary.rb
Overview
Details of a job. Jobs are scheduled instances of a job definition.
Constant Summary collapse
- LIFECYCLE_STATE_ENUM =
[ LIFECYCLE_STATE_ACTIVE = 'ACTIVE'.freeze, LIFECYCLE_STATE_INACTIVE = 'INACTIVE'.freeze, LIFECYCLE_STATE_EXPIRED = 'EXPIRED'.freeze, LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- JOB_TYPE_ENUM =
[ JOB_TYPE_HARVEST = 'HARVEST'.freeze, JOB_TYPE_PROFILING = 'PROFILING'.freeze, JOB_TYPE_SAMPLING = 'SAMPLING'.freeze, JOB_TYPE_PREVIEW = 'PREVIEW'.freeze, JOB_TYPE_IMPORT = 'IMPORT'.freeze, JOB_TYPE_EXPORT = 'EXPORT'.freeze, JOB_TYPE_IMPORT_GLOSSARY = 'IMPORT_GLOSSARY'.freeze, JOB_TYPE_EXPORT_GLOSSARY = 'EXPORT_GLOSSARY'.freeze, JOB_TYPE_INTERNAL = 'INTERNAL'.freeze, JOB_TYPE_PURGE = 'PURGE'.freeze, JOB_TYPE_IMMEDIATE = 'IMMEDIATE'.freeze, JOB_TYPE_SCHEDULED = 'SCHEDULED'.freeze, JOB_TYPE_IMMEDIATE_EXECUTION = 'IMMEDIATE_EXECUTION'.freeze, JOB_TYPE_SCHEDULED_EXECUTION = 'SCHEDULED_EXECUTION'.freeze, JOB_TYPE_SCHEDULED_EXECUTION_INSTANCE = 'SCHEDULED_EXECUTION_INSTANCE'.freeze, JOB_TYPE_ASYNC_DELETE = 'ASYNC_DELETE'.freeze, JOB_TYPE_IMPORT_DATA_ASSET = 'IMPORT_DATA_ASSET'.freeze, JOB_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#catalog_id ⇒ String
The data catalog's OCID.
-
#created_by_id ⇒ String
OCID of the user who created this job.
-
#data_asset_key ⇒ String
Unique key of the data asset to which this job applies, if the job involves a data asset.
-
#description ⇒ String
Detailed description of the job.
-
#display_name ⇒ String
A user-friendly display name.
-
#error_code ⇒ String
Error code returned from the latest job execution for this job.
-
#error_message ⇒ String
Error message returned from the latest job execution for this job.
-
#execution_count ⇒ Integer
The total number of executions for this job schedule.
-
#executions ⇒ Array<OCI::DataCatalog::Models::JobExecutionSummary>
Array of the executions summary associated with this job.
-
#job_definition_key ⇒ String
The unique key of the job definition resource that defined the scope of this job.
-
#job_definition_name ⇒ String
The display name of the job definition resource that defined the scope of this job.
-
#job_type ⇒ String
Type of the job.
-
#key ⇒ String
**[Required]** Unique key of the job.
-
#lifecycle_state ⇒ String
Lifecycle state of the job, such as running, paused, or completed.
-
#schedule_cron_expression ⇒ String
Interval on which the job will be run.
-
#schedule_type ⇒ String
Type of job schedule that is inferred from the scheduling properties.
-
#time_created ⇒ DateTime
The date and time the job was created, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339).
-
#time_of_latest_execution ⇒ DateTime
The date and time of the most recent execution for this job, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339).
-
#time_schedule_begin ⇒ DateTime
Date that the schedule should be operational.
-
#time_updated ⇒ DateTime
Time that this job was last updated.
-
#updated_by_id ⇒ String
OCID of the user who updated this job.
-
#uri ⇒ String
URI to the job instance in the API.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ JobSummary
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ JobSummary
Initializes the object
227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 227 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.key = attributes[:'key'] if attributes[:'key'] self.uri = attributes[:'uri'] if attributes[:'uri'] self.display_name = attributes[:'displayName'] if attributes[:'displayName'] raise 'You cannot provide both :displayName and :display_name' if attributes.key?(:'displayName') && attributes.key?(:'display_name') self.display_name = attributes[:'display_name'] if attributes[:'display_name'] self.catalog_id = attributes[:'catalogId'] if attributes[:'catalogId'] raise 'You cannot provide both :catalogId and :catalog_id' if attributes.key?(:'catalogId') && attributes.key?(:'catalog_id') self.catalog_id = attributes[:'catalog_id'] if attributes[:'catalog_id'] self.job_definition_key = attributes[:'jobDefinitionKey'] if attributes[:'jobDefinitionKey'] raise 'You cannot provide both :jobDefinitionKey and :job_definition_key' if attributes.key?(:'jobDefinitionKey') && attributes.key?(:'job_definition_key') self.job_definition_key = attributes[:'job_definition_key'] if attributes[:'job_definition_key'] self.lifecycle_state = attributes[:'lifecycleState'] if attributes[:'lifecycleState'] raise 'You cannot provide both :lifecycleState and :lifecycle_state' if attributes.key?(:'lifecycleState') && attributes.key?(:'lifecycle_state') self.lifecycle_state = attributes[:'lifecycle_state'] if attributes[:'lifecycle_state'] self.job_type = attributes[:'jobType'] if attributes[:'jobType'] raise 'You cannot provide both :jobType and :job_type' if attributes.key?(:'jobType') && attributes.key?(:'job_type') self.job_type = attributes[:'job_type'] if attributes[:'job_type'] self.schedule_type = attributes[:'scheduleType'] if attributes[:'scheduleType'] raise 'You cannot provide both :scheduleType and :schedule_type' if attributes.key?(:'scheduleType') && attributes.key?(:'schedule_type') self.schedule_type = attributes[:'schedule_type'] if attributes[:'schedule_type'] self.description = attributes[:'description'] if attributes[:'description'] self.time_created = attributes[:'timeCreated'] if attributes[:'timeCreated'] raise 'You cannot provide both :timeCreated and :time_created' if attributes.key?(:'timeCreated') && attributes.key?(:'time_created') self.time_created = attributes[:'time_created'] if attributes[:'time_created'] self.time_updated = attributes[:'timeUpdated'] if attributes[:'timeUpdated'] raise 'You cannot provide both :timeUpdated and :time_updated' if attributes.key?(:'timeUpdated') && attributes.key?(:'time_updated') self.time_updated = attributes[:'time_updated'] if attributes[:'time_updated'] self.created_by_id = attributes[:'createdById'] if attributes[:'createdById'] raise 'You cannot provide both :createdById and :created_by_id' if attributes.key?(:'createdById') && attributes.key?(:'created_by_id') self.created_by_id = attributes[:'created_by_id'] if attributes[:'created_by_id'] self.updated_by_id = attributes[:'updatedById'] if attributes[:'updatedById'] raise 'You cannot provide both :updatedById and :updated_by_id' if attributes.key?(:'updatedById') && attributes.key?(:'updated_by_id') self.updated_by_id = attributes[:'updated_by_id'] if attributes[:'updated_by_id'] self.schedule_cron_expression = attributes[:'scheduleCronExpression'] if attributes[:'scheduleCronExpression'] raise 'You cannot provide both :scheduleCronExpression and :schedule_cron_expression' if attributes.key?(:'scheduleCronExpression') && attributes.key?(:'schedule_cron_expression') self.schedule_cron_expression = attributes[:'schedule_cron_expression'] if attributes[:'schedule_cron_expression'] self.time_schedule_begin = attributes[:'timeScheduleBegin'] if attributes[:'timeScheduleBegin'] raise 'You cannot provide both :timeScheduleBegin and :time_schedule_begin' if attributes.key?(:'timeScheduleBegin') && attributes.key?(:'time_schedule_begin') self.time_schedule_begin = attributes[:'time_schedule_begin'] if attributes[:'time_schedule_begin'] self.execution_count = attributes[:'executionCount'] if attributes[:'executionCount'] raise 'You cannot provide both :executionCount and :execution_count' if attributes.key?(:'executionCount') && attributes.key?(:'execution_count') self.execution_count = attributes[:'execution_count'] if attributes[:'execution_count'] self.time_of_latest_execution = attributes[:'timeOfLatestExecution'] if attributes[:'timeOfLatestExecution'] raise 'You cannot provide both :timeOfLatestExecution and :time_of_latest_execution' if attributes.key?(:'timeOfLatestExecution') && attributes.key?(:'time_of_latest_execution') self.time_of_latest_execution = attributes[:'time_of_latest_execution'] if attributes[:'time_of_latest_execution'] self.job_definition_name = attributes[:'jobDefinitionName'] if attributes[:'jobDefinitionName'] raise 'You cannot provide both :jobDefinitionName and :job_definition_name' if attributes.key?(:'jobDefinitionName') && attributes.key?(:'job_definition_name') self.job_definition_name = attributes[:'job_definition_name'] if attributes[:'job_definition_name'] self.data_asset_key = attributes[:'dataAssetKey'] if attributes[:'dataAssetKey'] raise 'You cannot provide both :dataAssetKey and :data_asset_key' if attributes.key?(:'dataAssetKey') && attributes.key?(:'data_asset_key') self.data_asset_key = attributes[:'data_asset_key'] if attributes[:'data_asset_key'] self.error_code = attributes[:'errorCode'] if attributes[:'errorCode'] raise 'You cannot provide both :errorCode and :error_code' if attributes.key?(:'errorCode') && attributes.key?(:'error_code') self.error_code = attributes[:'error_code'] if attributes[:'error_code'] self. = attributes[:'errorMessage'] if attributes[:'errorMessage'] raise 'You cannot provide both :errorMessage and :error_message' if attributes.key?(:'errorMessage') && attributes.key?(:'error_message') self. = attributes[:'error_message'] if attributes[:'error_message'] self.executions = attributes[:'executions'] if attributes[:'executions'] end |
Instance Attribute Details
#catalog_id ⇒ String
The data catalog's OCID.
56 57 58 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 56 def catalog_id @catalog_id end |
#created_by_id ⇒ String
OCID of the user who created this job.
90 91 92 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 90 def created_by_id @created_by_id end |
#data_asset_key ⇒ String
Unique key of the data asset to which this job applies, if the job involves a data asset.
123 124 125 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 123 def data_asset_key @data_asset_key end |
#description ⇒ String
Detailed description of the job.
76 77 78 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 76 def description @description end |
#display_name ⇒ String
A user-friendly display name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
52 53 54 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 52 def display_name @display_name end |
#error_code ⇒ String
Error code returned from the latest job execution for this job. Useful when the latest Job execution is in FAILED state.
128 129 130 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 128 def error_code @error_code end |
#error_message ⇒ String
Error message returned from the latest job execution for this job. Useful when the latest Job Execution is in a FAILED state.
133 134 135 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 133 def @error_message end |
#execution_count ⇒ Integer
The total number of executions for this job schedule.
109 110 111 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 109 def execution_count @execution_count end |
#executions ⇒ Array<OCI::DataCatalog::Models::JobExecutionSummary>
Array of the executions summary associated with this job.
137 138 139 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 137 def executions @executions end |
#job_definition_key ⇒ String
The unique key of the job definition resource that defined the scope of this job.
60 61 62 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 60 def job_definition_key @job_definition_key end |
#job_definition_name ⇒ String
The display name of the job definition resource that defined the scope of this job.
119 120 121 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 119 def job_definition_name @job_definition_name end |
#job_type ⇒ String
Type of the job.
68 69 70 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 68 def job_type @job_type end |
#key ⇒ String
**[Required]** Unique key of the job.
42 43 44 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 42 def key @key end |
#lifecycle_state ⇒ String
Lifecycle state of the job, such as running, paused, or completed.
64 65 66 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 64 def lifecycle_state @lifecycle_state end |
#schedule_cron_expression ⇒ String
Interval on which the job will be run. Value is specified as a cron-supported time specification "nickname". The following subset of those is supported: @monthly, @weekly, @daily, @hourly.
100 101 102 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 100 def schedule_cron_expression @schedule_cron_expression end |
#schedule_type ⇒ String
Type of job schedule that is inferred from the scheduling properties.
72 73 74 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 72 def schedule_type @schedule_type end |
#time_created ⇒ DateTime
The date and time the job was created, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339). Example: `2019-03-25T21:10:29.600Z`
82 83 84 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 82 def time_created @time_created end |
#time_of_latest_execution ⇒ DateTime
The date and time of the most recent execution for this job, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339). Example: `2019-03-25T21:10:29.600Z`
115 116 117 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 115 def time_of_latest_execution @time_of_latest_execution end |
#time_schedule_begin ⇒ DateTime
Date that the schedule should be operational. An [RFC3339](tools.ietf.org/html/rfc3339) formatted datetime string.
104 105 106 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 104 def time_schedule_begin @time_schedule_begin end |
#time_updated ⇒ DateTime
Time that this job was last updated. An [RFC3339](tools.ietf.org/html/rfc3339) formatted datetime string.
86 87 88 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 86 def time_updated @time_updated end |
#updated_by_id ⇒ String
OCID of the user who updated this job.
94 95 96 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 94 def updated_by_id @updated_by_id end |
#uri ⇒ String
URI to the job instance in the API.
46 47 48 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 46 def uri @uri end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 140 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'key': :'key', 'uri': :'uri', 'display_name': :'displayName', 'catalog_id': :'catalogId', 'job_definition_key': :'jobDefinitionKey', 'lifecycle_state': :'lifecycleState', 'job_type': :'jobType', 'schedule_type': :'scheduleType', 'description': :'description', 'time_created': :'timeCreated', 'time_updated': :'timeUpdated', 'created_by_id': :'createdById', 'updated_by_id': :'updatedById', 'schedule_cron_expression': :'scheduleCronExpression', 'time_schedule_begin': :'timeScheduleBegin', 'execution_count': :'executionCount', 'time_of_latest_execution': :'timeOfLatestExecution', 'job_definition_name': :'jobDefinitionName', 'data_asset_key': :'dataAssetKey', 'error_code': :'errorCode', 'error_message': :'errorMessage', 'executions': :'executions' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 170 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'key': :'String', 'uri': :'String', 'display_name': :'String', 'catalog_id': :'String', 'job_definition_key': :'String', 'lifecycle_state': :'String', 'job_type': :'String', 'schedule_type': :'String', 'description': :'String', 'time_created': :'DateTime', 'time_updated': :'DateTime', 'created_by_id': :'String', 'updated_by_id': :'String', 'schedule_cron_expression': :'String', 'time_schedule_begin': :'DateTime', 'execution_count': :'Integer', 'time_of_latest_execution': :'DateTime', 'job_definition_name': :'String', 'data_asset_key': :'String', 'error_code': :'String', 'error_message': :'String', 'executions': :'Array<OCI::DataCatalog::Models::JobExecutionSummary>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 383 def ==(other) return true if equal?(other) self.class == other.class && key == other.key && uri == other.uri && display_name == other.display_name && catalog_id == other.catalog_id && job_definition_key == other.job_definition_key && lifecycle_state == other.lifecycle_state && job_type == other.job_type && schedule_type == other.schedule_type && description == other.description && time_created == other.time_created && time_updated == other.time_updated && created_by_id == other.created_by_id && updated_by_id == other.updated_by_id && schedule_cron_expression == other.schedule_cron_expression && time_schedule_begin == other.time_schedule_begin && execution_count == other.execution_count && time_of_latest_execution == other.time_of_latest_execution && job_definition_name == other.job_definition_name && data_asset_key == other.data_asset_key && error_code == other.error_code && == other. && executions == other.executions end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 434 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
414 415 416 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 414 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
423 424 425 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 423 def hash [key, uri, display_name, catalog_id, job_definition_key, lifecycle_state, job_type, schedule_type, description, time_created, time_updated, created_by_id, updated_by_id, schedule_cron_expression, time_schedule_begin, execution_count, time_of_latest_execution, job_definition_name, data_asset_key, error_code, , executions].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
467 468 469 470 471 472 473 474 475 476 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 467 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
461 462 463 |
# File 'lib/oci/data_catalog/models/job_summary.rb', line 461 def to_s to_hash.to_s end |