本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。
UpdateJob
虽然有一份工作JobState
价值是New
,您可以更新与任务相关的某些信息。一旦作业更改为不同的作业状态(通常在创建任务后 60 分钟内),此操作将不再可用。
请求语法
{
"AddressId": "string
",
"Description": "string
",
"ForwardingAddressId": "string
",
"JobId": "string
",
"Notification": {
"DevicePickupSnsTopicARN": "string
",
"JobStatesToNotify": [ "string
" ],
"NotifyAll": boolean
,
"SnsTopicARN": "string
"
},
"OnDeviceServiceConfiguration": {
"EKSOnDeviceService": {
"EKSAnywhereVersion": "string
",
"KubernetesVersion": "string
"
},
"NFSOnDeviceService": {
"StorageLimit": number
,
"StorageUnit": "string
"
},
"S3OnDeviceService": {
"FaultTolerance": number
,
"ServiceSize": number
,
"StorageLimit": number
,
"StorageUnit": "string
"
},
"TGWOnDeviceService": {
"StorageLimit": number
,
"StorageUnit": "string
"
}
},
"PickupDetails": {
"DevicePickupId": "string
",
"Email": "string
",
"IdentificationExpirationDate": number
,
"IdentificationIssuingOrg": "string
",
"IdentificationNumber": "string
",
"Name": "string
",
"PhoneNumber": "string
"
},
"Resources": {
"Ec2AmiResources": [
{
"AmiId": "string
",
"SnowballAmiId": "string
"
}
],
"LambdaResources": [
{
"EventTriggers": [
{
"EventResourceARN": "string
"
}
],
"LambdaArn": "string
"
}
],
"S3Resources": [
{
"BucketArn": "string
",
"KeyRange": {
"BeginMarker": "string
",
"EndMarker": "string
"
},
"TargetOnDeviceServices": [
{
"ServiceName": "string
",
"TransferOption": "string
"
}
]
}
]
},
"RoleARN": "string
",
"ShippingOption": "string
",
"SnowballCapacityPreference": "string
"
}
请求参数
有关所有操作的通用参数的信息,请参见常用参数。
请求接受采用 JSON 格式的以下数据。
- AddressId
-
更新后的 IDAddress对象。
类型:字符串
长度限制:固定长度为 40。
模式:
ADID[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}
必需:否
- Description
-
这份工作的最新描述JobMetadata对象。
类型:字符串
长度限制:最小长度为 1。长度上限为 1024。
模式:
.*
必需:否
- ForwardingAddressId
-
您所在的地区不支持此字段。
类型:字符串
长度限制:固定长度为 40。
模式:
ADID[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}
必需:否
- JobId
-
您要更新的任务的作业 ID,例如
JID123e4567-e89b-12d3-a456-426655440000
。类型:字符串
长度限制:固定长度为 39。
模式:
(M|J)ID[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}
必需:是
- Notification
-
新的或更新的Notification对象。
类型:Notification 对象
必需:否
- OnDeviceServiceConfiguration
-
在 Snow Family 设备上指定 Snow Family 设备上将传输的数据导出或导入的服务。AmazonSnow Family 支持亚马逊 S3 和 NFS(网络文件系统)以及Amazon存储网关服务磁带网关类型。
类型:OnDeviceServiceConfiguration 对象
必需:否
- PickupDetails
-
识别拿起设备的人的信息。
类型:PickupDetails 对象
必需:否
- Resources
-
更新后的
JobResource
对象,或者更新的JobResource对象。类型:JobResource 对象
必需:否
- RoleARN
-
您要与此任务关联的新角色亚马逊资源名称 (ARN)。要创建角色 ARN,请使用CreateRole Amazon Identity and Access Management(IAM) API 操作。
类型:字符串
长度限制:最大长度为 255。
模式:
arn:aws.*:iam::[0-9]{12}:role/.*
必需:否
- ShippingOption
-
此任务的更新配送选项值ShippingDetails对象。
类型:字符串
有效值:
SECOND_DAY | NEXT_DAY | EXPRESS | STANDARD
必需:否
- SnowballCapacityPreference
-
更新后的
SnowballCapacityPreference
这份工作的JobMetadata对象。50 TB Snowball 仅在美国地区可用。有关 Snow Family 设备类型的信息,请参见Snow 系列设备和容量在Snowcone 用户指南要么Snow 系列设备和容量在《雪球边缘》用户指南。
类型:字符串
有效值:
T50 | T80 | T100 | T42 | T98 | T8 | T14 | T32 | NoPreference | T240 | T13
必需:否
响应元素
如果此操作成功,则该服务会发送回带有空 HTTP 正文的 HTTP 200 响应。
错误
有关所有操作常见错误的信息,请参见常见错误。
- ClusterLimitExceededException
-
创建任务失败。目前,集群支持五个节点。如果您的群集少于五个节点,并且要为该集群创建更多节点,请重试并创建任务,直到您的集群恰好有五个节点。
HTTP 状态代码:400
- Ec2RequestFailedException
-
您的用户缺乏执行尝试操作所必需的 Amazon EC2 权限。
HTTP 状态代码:400
- InvalidInputCombinationException
-
任务或集群创建失败。一个或多个输入无效。确认CreateCluster:SnowballType价值支持你的CreateJob:JobType,然后再试一次。
HTTP 状态代码:400
- InvalidJobStateException
-
无法执行该操作,因为作业的当前状态不允许执行该操作。
HTTP 状态代码:400
- InvalidResourceException
-
找不到指定的资源。检查您在上次请求中提供的信息,然后重试。
HTTP 状态代码:400
- KMSRequestFailedException
-
提供的Amazon Key Management Servicekey 缺少执行指定操作的权限CreateJob要么UpdateJob行动。
HTTP 状态代码:400
另请参阅
有关在特定语言的 Amazon 软件开发工具包中使用此 API 的更多信息,请参阅以下内容: