ジョブ
ジョブの実行
Qiskit Runtime プリミティブを呼び出す。
許可
このメソッドを呼び出すには、以下のアクションを含む1つ以上のIAMアクセス・ロールが割り当てられている必要があります。 アクセス状況を確認するには、次に移動してください。 Users > User > Access
quantum-computing.direct-access-job.create
監査
このメソッドを呼び出すと、以下の監査イベントが生成されます。
quantum-computing.direct-access-job.create
入力
名前、タイプ | 説明 |
|---|---|
backend 必須 string | バックエンド名 例: "ibm_rensselaer" |
id 必須 string | ジョブ識別子。 UUIDが推奨されます |
log_level string | プログラムのログレベル 使用可能な値: infodebugwarningerrorcriticalデフォルト値: warning |
program_id 必須 string | プログラムのID 例: "sampler" |
storage 必須 object | |
timeout_secs 必須 integer | ジョブがタイムアウトしてキャンセルされるまでの時間(秒単位)。 システム実行時間(壁時計時間ではない)に基づいています。 システム実行時間とは、システムがお客様のジョブ処理に専念する時間の量です。 |
curl -X POST \
'<YOUR_QSA_URL>/v1/jobs' \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-d '{"id":"example","program_id":"sampler","backend":"ibm_rensselaer","timeout_secs":1,"storage":{}}'import requests
response = requests.request(
"POST",
"<YOUR_QSA_URL>/v1/jobs",
headers={
"Accept": "application/json",
"Content-Type": "application/json"
},
data="{\"id\":\"example\",\"program_id\":\"sampler\",\"backend\":\"ibm_rensselaer\",\"timeout_secs\":1,\"storage\":{}}"
)
print(response.json())出力
状況コード | 説明 |
|---|---|
| 204 | ジョブが正常に送信されたときに返されます。 |
| 400 | 無効な入力が受信された場合に返されます。 |
| 401 | 認証に失敗したため返却されました。 |
| 404 | バックエンドが見つからなかった場合に返される |
| 408 | リクエストの読み取りに時間がかかりすぎたため返却されました。 |
| 409 | 同じジョブIDを持つ重複ジョブが送信された場合に返されます。 |
| 413 | リクエスト本文が大きすぎる場合に返されます。 |
| 422 | リクエストの検証に失敗したときに返されます。 エラーメッセージには、特定の検証エラーに関する詳細が含まれています。 |
| 423 | リクエストされたバックエンドは予約済みであり、予約範囲外のジョブは実行できません。 |
| 429 | バックエンドの同時ジョブ制限に達したときに返されます。 既存のジョブが終了したら、再度試行してください。終了したジョブを削除して、さらにジョブを送信してください。 |
ジョブの取得
現在の認証済みクライアントによって送信されたすべてのジョブのリストを取得します。作成時刻の昇順で並べ替えられます。
許可
このメソッドを呼び出すには、以下のアクションを含む1つ以上のIAMアクセス・ロールが割り当てられている必要があります。 アクセス状況を確認するには、次に移動してください。 Users > User > Access
quantum-computing.direct-access-job.list
監査
このメソッドを呼び出すと、以下の監査イベントが生成されます。
quantum-computing.direct-access-job.list
入力
情報 |
|---|
| このエンドポイントは入力を受け付けません。 |
curl -X GET \
'<YOUR_QSA_URL>/v1/jobs' \
-H 'Accept: application/json'import requests
response = requests.request(
"GET",
"<YOUR_QSA_URL>/v1/jobs",
headers={
"Accept": "application/json"
},
)
print(response.json())出力
状況コード | 説明 |
|---|---|
| 200 | ジョブが正常に取得されたときに返されます。 |
| 401 | 認証に失敗したため返却されました。 |
{
"jobs": [
{
"backend": "ibm_rensselaer",
"created_time": "example",
"end_time": "example",
"id": "example",
"log_level": "info",
"metrics": {
"circuits_execution_time_ns": 1,
"timestamps": {
"created": "example",
"finished": "example"
}
},
"program_id": "sampler",
"reason_code": 1,
"reason_message": "example",
"reason_solution": "example",
"status": "Running",
"storage": {
"input": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
},
"logs": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
},
"results": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
}
},
"timeout_secs": 1,
"usage": {
"quantum_nanoseconds": 1
}
}
]
}{
"additionalProperties": false,
"properties": {
"jobs": {
"items": {
"additionalProperties": false,
"properties": {
"backend": {
"description": "バックエンド名",
"examples": [
"ibm_rensselaer"
],
"type": "string"
},
"created_time": {
"description": "ジョブが作成された時刻。",
"format": "date-time",
"type": "string"
},
"end_time": {
"description": "ジョブが終了状態に達した時刻。",
"format": "date-time",
"type": "string"
},
"id": {
"description": "ジョブ固有ID( V4 のUUID)",
"type": "string"
},
"log_level": {
"description": "プログラムのログレベル",
"enum": [
"info",
"debug",
"warning",
"error",
"critical"
],
"type": "string"
},
"metrics": {
"description": "ジョブの実行メトリクス。",
"additionalProperties": false,
"properties": {
"circuits_execution_time_ns": {
"description": "QPU における回路の実行時間の合計(ナノ秒単位)。",
"format": "int64",
"type": "integer"
},
"timestamps": {
"description": "ジョブのライフサイクルにおけるタイムスタンプ。",
"additionalProperties": false,
"properties": {
"created": {
"description": "そのジョブが作成された時刻。",
"format": "date-time",
"type": "string"
},
"finished": {
"description": "その仕事が最終段階に達した時期。",
"format": "date-time",
"type": "string"
}
},
"required": [
"created"
],
"type": "object"
}
},
"required": [
"timestamps"
],
"type": "object"
},
"program_id": {
"description": "プログラムのID",
"examples": [
"sampler"
],
"type": "string"
},
"reason_code": {
"description": "このフィールドは、ジョブが失敗した場合に数値エラーコードが設定されます。",
"format": "int64",
"type": "integer"
},
"reason_message": {
"description": "ジョブが特定のステータスにある理由を説明するメッセージ。 例:ジョブが失敗した場合、このフィールドにはエラーメッセージが表示されます。",
"type": "string"
},
"reason_solution": {
"description": "失敗した場合の次の手順。",
"type": "string"
},
"status": {
"description": "現在のジョブの状況。",
"enum": [
"Running",
"Completed",
"Cancelled",
"Failed"
],
"type": "string"
},
"storage": {
"additionalProperties": false,
"properties": {
"input": {
"description": "入力が読み込まれる場所。 プリミティブプログラムに必須。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"logs": {
"description": "ジョブログが保存される場所。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"results": {
"description": "ジョブ結果が保存される場所。 プリミティブプログラムに必須。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
}
},
"type": "object"
},
"timeout_secs": {
"description": "ジョブがタイムアウトしてキャンセルされるまでの時間(秒単位)。",
"format": "int64",
"type": "integer"
},
"usage": {
"description": "ジョブ使用の詳細。",
"additionalProperties": false,
"properties": {
"quantum_nanoseconds": {
"description": "量子デバイス上での実行時間(ナノ秒単位)",
"format": "int64",
"type": "integer"
}
},
"type": "object"
}
},
"required": [
"id",
"program_id",
"backend",
"status",
"created_time"
],
"type": "object"
},
"type": [
"array",
"null"
]
}
},
"required": [
"jobs"
],
"type": "object"
}IDで求人を探す
現在の認証済みクライアントに対して、一意の識別子で単一のジョブを取得します。
許可
このメソッドを呼び出すには、以下のアクションを含む1つ以上のIAMアクセス・ロールが割り当てられている必要があります。 アクセス状況を確認するには、次に移動してください。 Users > User > Access
quantum-computing.direct-access-job.read
監査
このメソッドを呼び出すと、以下の監査イベントが生成されます。
quantum-computing.direct-access-job.read
入力
名前、タイプ | 説明 |
|---|---|
job-id 必須 string |
curl -X GET \
'<YOUR_QSA_URL>/v1/jobs/{job-id}' \
-H 'Accept: application/json'import requests
response = requests.request(
"GET",
"<YOUR_QSA_URL>/v1/jobs/{job-id}",
headers={
"Accept": "application/json"
},
)
print(response.json())出力
状況コード | 説明 |
|---|---|
| 200 | ジョブが正常に取得されました。 |
| 401 | 認証に失敗したため返却されました。 |
| 404 | 認証済みクライアントに属する指定されたIDに対応するジョブが見つかりませんでした。 |
{
"backend": "ibm_rensselaer",
"created_time": "example",
"end_time": "example",
"id": "example",
"log_level": "info",
"metrics": {
"circuits_execution_time_ns": 1,
"timestamps": {
"created": "example",
"finished": "example"
}
},
"program_id": "sampler",
"reason_code": 1,
"reason_message": "example",
"reason_solution": "example",
"status": "Running",
"storage": {
"input": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
},
"logs": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
},
"results": {
"bucket_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket",
"object_name": "example",
"presigned_url": "example",
"region": "us-east",
"region_type": "regional",
"runtime_instance_crn": "crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::",
"type": "s3_compatible"
}
},
"timeout_secs": 1,
"usage": {
"quantum_nanoseconds": 1
}
}{
"additionalProperties": false,
"properties": {
"backend": {
"description": "バックエンド名",
"examples": [
"ibm_rensselaer"
],
"type": "string"
},
"created_time": {
"description": "ジョブが作成された時刻。",
"format": "date-time",
"type": "string"
},
"end_time": {
"description": "ジョブが終了状態に達した時刻。",
"format": "date-time",
"type": "string"
},
"id": {
"description": "ジョブ固有ID( V4 のUUID)",
"type": "string"
},
"log_level": {
"description": "プログラムのログレベル",
"enum": [
"info",
"debug",
"warning",
"error",
"critical"
],
"type": "string"
},
"metrics": {
"description": "ジョブの実行メトリクス。",
"additionalProperties": false,
"properties": {
"circuits_execution_time_ns": {
"description": "QPU における回路の実行時間の合計(ナノ秒単位)。",
"format": "int64",
"type": "integer"
},
"timestamps": {
"description": "ジョブのライフサイクルにおけるタイムスタンプ。",
"additionalProperties": false,
"properties": {
"created": {
"description": "そのジョブが作成された時刻。",
"format": "date-time",
"type": "string"
},
"finished": {
"description": "その仕事が最終段階に達した時期。",
"format": "date-time",
"type": "string"
}
},
"required": [
"created"
],
"type": "object"
}
},
"required": [
"timestamps"
],
"type": "object"
},
"program_id": {
"description": "プログラムのID",
"examples": [
"sampler"
],
"type": "string"
},
"reason_code": {
"description": "このフィールドは、ジョブが失敗した場合に数値エラーコードが設定されます。",
"format": "int64",
"type": "integer"
},
"reason_message": {
"description": "ジョブが特定のステータスにある理由を説明するメッセージ。 例:ジョブが失敗した場合、このフィールドにはエラーメッセージが表示されます。",
"type": "string"
},
"reason_solution": {
"description": "失敗した場合の次の手順。",
"type": "string"
},
"status": {
"description": "現在のジョブの状況。",
"enum": [
"Running",
"Completed",
"Cancelled",
"Failed"
],
"type": "string"
},
"storage": {
"additionalProperties": false,
"properties": {
"input": {
"description": "入力が読み込まれる場所。 プリミティブプログラムに必須。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"logs": {
"description": "ジョブログが保存される場所。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
},
"results": {
"description": "ジョブ結果が保存される場所。 プリミティブプログラムに必須。",
"additionalProperties": false,
"properties": {
"bucket_crn": {
"description": "ターゲット Cloud Object Storage バケットに対する完全な CRN の指定 typeが ibmcloud_cos の場合、bucket\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:cloud-object-storage:global:a/abc123:abc123:bucket:my-bucket"
],
"type": "string"
},
"object_name": {
"description": "IBM Cloud Object Storage バケット内のオブジェクトの名前/ID。 type が ibmcloud_cos の場合、object\\_name は必須です",
"type": "string"
},
"presigned_url": {
"description": "事前署名済みGETまたはPUT URL(ジョブパラメータの読み取り、結果やログの書き込み用) type が s3_compatible の場合、presigned\\_url は必須です",
"type": "string"
},
"region": {
"description": "typeが ibmcloud_cos の場合、regionは必須です",
"examples": [
"us-east"
],
"pattern": "^[a-zA-Z-]+$",
"type": "string"
},
"region_type": {
"description": "IBM Cloud Object Storage ( [https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-endpoints) )で定義されるリージョン、クロスリージョン、または単一データセンター。 typeが ibmcloud_cos の場合、region\\_typeは必須です",
"enum": [
"regional",
"cross-region",
"single-site"
],
"type": "string"
},
"runtime_instance_crn": {
"description": "提供されたストレージ場所へのアクセス権を持つランタイムインスタンスのサービスCRN。 typeが ibmcloud_cos の場合、runtime\\_instance\\_crnが必須です",
"examples": [
"crn:v1:bluemix:public:quantum-computing:us-east:a/abc123:abc123::"
],
"type": "string"
},
"type": {
"enum": [
"s3_compatible"
],
"type": "string"
}
},
"required": [
"type"
],
"type": "object"
}
},
"type": "object"
},
"timeout_secs": {
"description": "ジョブがタイムアウトしてキャンセルされるまでの時間(秒単位)。",
"format": "int64",
"type": "integer"
},
"usage": {
"description": "ジョブ使用の詳細。",
"additionalProperties": false,
"properties": {
"quantum_nanoseconds": {
"description": "量子デバイス上での実行時間(ナノ秒単位)",
"format": "int64",
"type": "integer"
}
},
"type": "object"
}
},
"required": [
"id",
"program_id",
"backend",
"status",
"created_time"
],
"type": "object"
}ジョブの削除
ジョブが終了している場合、それを削除します。
許可
このメソッドを呼び出すには、以下のアクションを含む1つ以上のIAMアクセス・ロールが割り当てられている必要があります。 アクセス状況を確認するには、次に移動してください。 Users > User > Access
quantum-computing.direct-access-job.delete
監査
このメソッドを呼び出すと、以下の監査イベントが生成されます。
quantum-computing.direct-access-job.delete
入力
名前、タイプ | 説明 |
|---|---|
job-id 必須 string |
curl -X DELETE \
'<YOUR_QSA_URL>/v1/jobs/{job-id}' \
-H 'Accept: application/json'import requests
response = requests.request(
"DELETE",
"<YOUR_QSA_URL>/v1/jobs/{job-id}",
headers={
"Accept": "application/json"
},
)
print(response.json())出力
状況コード | 説明 |
|---|---|
| 204 | ジョブが正常に削除されたときに返されます。 |
| 401 | 認証に失敗したため返却されました。 |
| 404 | ジョブが見つからない場合に返されます。 |
| 409 | ジョブがまだ終了しておらず、削除する前にキャンセルする必要がある場合に返されます。 |
ジョブをキャンセルします
ジョブがまだ終了していない場合、それをキャンセルします。
許可
このメソッドを呼び出すには、以下のアクションを含む1つ以上のIAMアクセス・ロールが割り当てられている必要があります。 アクセス状況を確認するには、次に移動してください。 Users > User > Access
quantum-computing.direct-access-job.cancel
監査
このメソッドを呼び出すと、以下の監査イベントが生成されます。
quantum-computing.direct-access-job.cancel
入力
名前、タイプ | 説明 |
|---|---|
job-id 必須 string |
curl -X POST \
'<YOUR_QSA_URL>/v1/jobs/{job-id}/cancel' \
-H 'Accept: application/json'import requests
response = requests.request(
"POST",
"<YOUR_QSA_URL>/v1/jobs/{job-id}/cancel",
headers={
"Accept": "application/json"
},
)
print(response.json())出力
状況コード | 説明 |
|---|---|
| 204 | ジョブキャンセル要求が正常に送信されたときに返されます。 |
| 401 | 認証に失敗したため返却されました。 |
| 404 | ジョブが見つからない場合に返されます。 |
| 409 | ジョブが既に終了しており、キャンセルできない場合に返されます。 |
| 500 | 内部サーバーエラーが発生した場合に返されます。 |