create_worker
async
¶
create_worker(
farm_id: FarmId,
fleet_id: FleetId,
*,
config_overrides: Optional[AsyncdeadlineClientConfig] = None,
host_properties: Optional[HostPropertiesRequest] = None,
client_token: Optional[ClientToken] = None,
tags: Optional[Tags] = None,
) -> CreateWorkerResponse
Creates a worker. A worker tells your instance how much processing power (vCPU), and memory (GiB) you’ll need to assemble the digital assets held within a particular instance. You can specify certain instance types to use, or let the worker know which instances types to exclude.
Deadline Cloud limits the number of workers to less than or equal to the fleet's maximum worker count. The service maintains eventual consistency for the worker count. If you make multiple rapid calls to CreateWorker before the field updates, you might exceed your fleet's maximum worker count. For example, if your maxWorkerCount is 10 and you currently have 9 workers, making two quick CreateWorker calls might successfully create 2 workers instead of 1, resulting in 11 total workers.
Parameters:
-
farm_id(FarmId) –The farm ID of the farm to connect to the worker.
-
fleet_id(FleetId) –The fleet ID to connect to the worker.
-
host_properties(Optional[HostPropertiesRequest], default:None) –The IP address and host name of the worker.
-
client_token(Optional[ClientToken], default:None) –The unique token which the server uses to recognize retries of the same request.
-
tags(Optional[Tags], default:None) –Each tag consists of a tag key and a tag value. Tag keys and values are both required, but tag values can be empty strings.
Raises:
-
AccessDeniedException–You don't have permission to perform the action.
-
ConflictException–Your request has conflicting operations. This can occur if you're trying to perform more than one operation on the same resource at the same time.
-
InternalServerErrorException–Deadline Cloud can't process your request right now. Try again later.
-
ResourceNotFoundException–The requested resource can't be found.
-
ThrottlingException–Your request exceeded a request rate quota.
-
ValidationException–The request isn't valid. This can occur if your request contains malformed JSON or unsupported characters.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_deadline/_services/async_deadline.py
5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 | |