Class: DockerEngineAPI::Models::Task
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- DockerEngineAPI::Models::Task
- Defined in:
- lib/docker_engine_api/models/task.rb
Overview
Defined Under Namespace
Modules: DesiredState Classes: AssignedGenericResource, JobIteration, Status, Version
Instance Attribute Summary collapse
-
#assigned_generic_resources ⇒ Array<DockerEngineAPI::Models::Task::AssignedGenericResource>?
User-defined resources can be either Integer resources (e.g, ‘SSD=3`) or String resources (e.g, `GPU=UUID1`).
- #created_at ⇒ String?
- #desired_state ⇒ Symbol, ...
-
#id ⇒ String?
The ID of the task.
-
#job_iteration ⇒ DockerEngineAPI::Models::Task::JobIteration?
The version number of the object such as node, service, etc.
-
#labels ⇒ Hash{Symbol=>String}?
User-defined key/value metadata.
-
#name ⇒ String?
Name of the task.
-
#node_id ⇒ String?
The ID of the node that this task is on.
-
#service_id ⇒ String?
The ID of the service this task is part of.
- #slot ⇒ Integer?
-
#spec ⇒ DockerEngineAPI::Models::Spec?
User modifiable task configuration.
-
#status ⇒ DockerEngineAPI::Models::Task::Status?
represents the status of a task.
- #updated_at ⇒ String?
-
#version ⇒ DockerEngineAPI::Models::Task::Version?
The version number of the object such as node, service, etc.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(index: nil) ⇒ Object
constructor
The version number of the object such as node, service, etc.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(index: nil) ⇒ Object
The version number of the object such as node, service, etc. This is needed to avoid conflicting writes. The client must send the version number along with the modified specification when updating these objects.
This approach ensures safe concurrency and determinism in that the change on the object may not be applied if the version number has changed from the last read. In other words, if two update requests specify the same base version, only one of the requests can succeed. As a result, two separate update requests that happen at the same time will not unintentionally overwrite each other.
|
|
# File 'lib/docker_engine_api/models/task.rb', line 188
|
Instance Attribute Details
#assigned_generic_resources ⇒ Array<DockerEngineAPI::Models::Task::AssignedGenericResource>?
User-defined resources can be either Integer resources (e.g, ‘SSD=3`) or String resources (e.g, `GPU=UUID1`).
12 13 14 15 16 |
# File 'lib/docker_engine_api/models/task.rb', line 12 optional :assigned_generic_resources, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Task::AssignedGenericResource] }, api_name: :AssignedGenericResources |
#created_at ⇒ String?
21 |
# File 'lib/docker_engine_api/models/task.rb', line 21 optional :created_at, String, api_name: :CreatedAt |
#desired_state ⇒ Symbol, ...
26 |
# File 'lib/docker_engine_api/models/task.rb', line 26 optional :desired_state, enum: -> { DockerEngineAPI::Task::DesiredState }, api_name: :DesiredState |
#id ⇒ String?
The ID of the task.
32 |
# File 'lib/docker_engine_api/models/task.rb', line 32 optional :id, String, api_name: :ID |
#job_iteration ⇒ DockerEngineAPI::Models::Task::JobIteration?
The version number of the object such as node, service, etc. This is needed to avoid conflicting writes. The client must send the version number along with the modified specification when updating these objects.
This approach ensures safe concurrency and determinism in that the change on the object may not be applied if the version number has changed from the last read. In other words, if two update requests specify the same base version, only one of the requests can succeed. As a result, two separate update requests that happen at the same time will not unintentionally overwrite each other.
46 |
# File 'lib/docker_engine_api/models/task.rb', line 46 optional :job_iteration, -> { DockerEngineAPI::Task::JobIteration }, api_name: :JobIteration |
#labels ⇒ Hash{Symbol=>String}?
User-defined key/value metadata.
52 |
# File 'lib/docker_engine_api/models/task.rb', line 52 optional :labels, DockerEngineAPI::Internal::Type::HashOf[String], api_name: :Labels |
#name ⇒ String?
Name of the task.
58 |
# File 'lib/docker_engine_api/models/task.rb', line 58 optional :name, String, api_name: :Name |
#node_id ⇒ String?
The ID of the node that this task is on.
64 |
# File 'lib/docker_engine_api/models/task.rb', line 64 optional :node_id, String, api_name: :NodeID |
#service_id ⇒ String?
The ID of the service this task is part of.
70 |
# File 'lib/docker_engine_api/models/task.rb', line 70 optional :service_id, String, api_name: :ServiceID |
#slot ⇒ Integer?
75 |
# File 'lib/docker_engine_api/models/task.rb', line 75 optional :slot, Integer, api_name: :Slot |
#spec ⇒ DockerEngineAPI::Models::Spec?
User modifiable task configuration.
81 |
# File 'lib/docker_engine_api/models/task.rb', line 81 optional :spec, -> { DockerEngineAPI::Spec }, api_name: :Spec |
#status ⇒ DockerEngineAPI::Models::Task::Status?
represents the status of a task.
87 |
# File 'lib/docker_engine_api/models/task.rb', line 87 optional :status, -> { DockerEngineAPI::Task::Status }, api_name: :Status |
#updated_at ⇒ String?
92 |
# File 'lib/docker_engine_api/models/task.rb', line 92 optional :updated_at, String, api_name: :UpdatedAt |
#version ⇒ DockerEngineAPI::Models::Task::Version?
The version number of the object such as node, service, etc. This is needed to avoid conflicting writes. The client must send the version number along with the modified specification when updating these objects.
This approach ensures safe concurrency and determinism in that the change on the object may not be applied if the version number has changed from the last read. In other words, if two update requests specify the same base version, only one of the requests can succeed. As a result, two separate update requests that happen at the same time will not unintentionally overwrite each other.
106 |
# File 'lib/docker_engine_api/models/task.rb', line 106 optional :version, -> { DockerEngineAPI::Task::Version }, api_name: :Version |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/docker_engine_api/models/task.rb', line 214
|