(::Google::Protobuf::Map{::String => ::String}) — Custom labels to apply to the job and any Cloud LoggingLogEntrythat it generates.
Use labels to group and describe the resources they are applied to. Batch
automatically applies predefined labels and supports multiplelabelsfields for each job, which each let you apply custom labels to various
resources. Label names that start with "goog-" or "google-" are
reserved for predefined labels. For more information about labels with
Batch, seeOrganize resources using
labels.
value(::Google::Protobuf::Map{::String => ::String}) — Custom labels to apply to the job and any Cloud LoggingLogEntrythat it generates.
Use labels to group and describe the resources they are applied to. Batch
automatically applies predefined labels and supports multiplelabelsfields for each job, which each let you apply custom labels to various
resources. Label names that start with "goog-" or "google-" are
reserved for predefined labels. For more information about labels with
Batch, seeOrganize resources using
labels.
Returns
(::Google::Protobuf::Map{::String => ::String}) — Custom labels to apply to the job and any Cloud LoggingLogEntrythat it generates.
Use labels to group and describe the resources they are applied to. Batch
automatically applies predefined labels and supports multiplelabelsfields for each job, which each let you apply custom labels to various
resources. Label names that start with "goog-" or "google-" are
reserved for predefined labels. For more information about labels with
Batch, seeOrganize resources using
labels.
(::Integer) — Priority of the Job.
The valid value range is [0, 100). Default value is 0.
Higher value indicates higher priority.
A job with higher priority value is more likely to run earlier if all other
requirements are satisfied.
#priority=
defpriority=(value)->::Integer
Parameter
value(::Integer) — Priority of the Job.
The valid value range is [0, 100). Default value is 0.
Higher value indicates higher priority.
A job with higher priority value is more likely to run earlier if all other
requirements are satisfied.
Returns
(::Integer) — Priority of the Job.
The valid value range is [0, 100). Default value is 0.
Higher value indicates higher priority.
A job with higher priority value is more likely to run earlier if all other
requirements are satisfied.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Batch V1 API - Class Google::Cloud::Batch::V1::Job (v1.2.0)\n\nVersion latestkeyboard_arrow_down\n\n- [1.2.0 (latest)](/ruby/docs/reference/google-cloud-batch-v1/latest/Google-Cloud-Batch-V1-Job)\n- [1.1.1](/ruby/docs/reference/google-cloud-batch-v1/1.1.1/Google-Cloud-Batch-V1-Job)\n- [1.0.0](/ruby/docs/reference/google-cloud-batch-v1/1.0.0/Google-Cloud-Batch-V1-Job)\n- [0.21.0](/ruby/docs/reference/google-cloud-batch-v1/0.21.0/Google-Cloud-Batch-V1-Job)\n- [0.20.1](/ruby/docs/reference/google-cloud-batch-v1/0.20.1/Google-Cloud-Batch-V1-Job)\n- [0.19.2](/ruby/docs/reference/google-cloud-batch-v1/0.19.2/Google-Cloud-Batch-V1-Job)\n- [0.18.3](/ruby/docs/reference/google-cloud-batch-v1/0.18.3/Google-Cloud-Batch-V1-Job)\n- [0.17.4](/ruby/docs/reference/google-cloud-batch-v1/0.17.4/Google-Cloud-Batch-V1-Job)\n- [0.16.2](/ruby/docs/reference/google-cloud-batch-v1/0.16.2/Google-Cloud-Batch-V1-Job)\n- [0.15.1](/ruby/docs/reference/google-cloud-batch-v1/0.15.1/Google-Cloud-Batch-V1-Job)\n- [0.14.0](/ruby/docs/reference/google-cloud-batch-v1/0.14.0/Google-Cloud-Batch-V1-Job)\n- [0.13.1](/ruby/docs/reference/google-cloud-batch-v1/0.13.1/Google-Cloud-Batch-V1-Job)\n- [0.12.0](/ruby/docs/reference/google-cloud-batch-v1/0.12.0/Google-Cloud-Batch-V1-Job)\n- [0.11.1](/ruby/docs/reference/google-cloud-batch-v1/0.11.1/Google-Cloud-Batch-V1-Job)\n- [0.10.5](/ruby/docs/reference/google-cloud-batch-v1/0.10.5/Google-Cloud-Batch-V1-Job)\n- [0.9.0](/ruby/docs/reference/google-cloud-batch-v1/0.9.0/Google-Cloud-Batch-V1-Job)\n- [0.8.0](/ruby/docs/reference/google-cloud-batch-v1/0.8.0/Google-Cloud-Batch-V1-Job)\n- [0.7.0](/ruby/docs/reference/google-cloud-batch-v1/0.7.0/Google-Cloud-Batch-V1-Job)\n- [0.6.0](/ruby/docs/reference/google-cloud-batch-v1/0.6.0/Google-Cloud-Batch-V1-Job)\n- [0.5.0](/ruby/docs/reference/google-cloud-batch-v1/0.5.0/Google-Cloud-Batch-V1-Job)\n- [0.4.3](/ruby/docs/reference/google-cloud-batch-v1/0.4.3/Google-Cloud-Batch-V1-Job)\n- [0.3.0](/ruby/docs/reference/google-cloud-batch-v1/0.3.0/Google-Cloud-Batch-V1-Job)\n- [0.2.0](/ruby/docs/reference/google-cloud-batch-v1/0.2.0/Google-Cloud-Batch-V1-Job)\n- [0.1.0](/ruby/docs/reference/google-cloud-batch-v1/0.1.0/Google-Cloud-Batch-V1-Job) \nReference documentation and code samples for the Batch V1 API class Google::Cloud::Batch::V1::Job.\n\nThe Cloud Batch Job description. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #allocation_policy\n\n def allocation_policy() -\u003e ::Google::Cloud::Batch::V1::AllocationPolicy\n\n**Returns**\n\n- ([::Google::Cloud::Batch::V1::AllocationPolicy](./Google-Cloud-Batch-V1-AllocationPolicy)) --- Compute resource allocation for all TaskGroups in the Job.\n\n### #allocation_policy=\n\n def allocation_policy=(value) -\u003e ::Google::Cloud::Batch::V1::AllocationPolicy\n\n**Parameter**\n\n- **value** ([::Google::Cloud::Batch::V1::AllocationPolicy](./Google-Cloud-Batch-V1-AllocationPolicy)) --- Compute resource allocation for all TaskGroups in the Job. \n**Returns**\n\n- ([::Google::Cloud::Batch::V1::AllocationPolicy](./Google-Cloud-Batch-V1-AllocationPolicy)) --- Compute resource allocation for all TaskGroups in the Job.\n\n### #create_time\n\n def create_time() -\u003e ::Google::Protobuf::Timestamp\n\n**Returns**\n\n- ([::Google::Protobuf::Timestamp](./Google-Protobuf-Timestamp)) --- Output only. When the Job was created.\n\n### #labels\n\n def labels() -\u003e ::Google::Protobuf::Map{::String =\u003e ::String}\n\n**Returns**\n\n- (::Google::Protobuf::Map{::String =\\\u003e ::String}) --- Custom labels to apply to the job and any Cloud Logging [LogEntry](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry) that it generates.\n\n\n Use labels to group and describe the resources they are applied to. Batch\n automatically applies predefined labels and supports multiple `labels`\n fields for each job, which each let you apply custom labels to various\n resources. Label names that start with \"goog-\" or \"google-\" are\n reserved for predefined labels. For more information about labels with\n Batch, see\n [Organize resources using\n labels](https://cloud.google.com/batch/docs/organize-resources-using-labels).\n\n### #labels=\n\n def labels=(value) -\u003e ::Google::Protobuf::Map{::String =\u003e ::String}\n\n**Parameter**\n\n- **value** (::Google::Protobuf::Map{::String =\\\u003e ::String}) --- Custom labels to apply to the job and any Cloud Logging [LogEntry](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry) that it generates.\n\n\n Use labels to group and describe the resources they are applied to. Batch\n automatically applies predefined labels and supports multiple `labels`\n fields for each job, which each let you apply custom labels to various\n resources. Label names that start with \"goog-\" or \"google-\" are\n reserved for predefined labels. For more information about labels with\n Batch, see\n [Organize resources using\nlabels](https://cloud.google.com/batch/docs/organize-resources-using-labels). \n**Returns**\n\n- (::Google::Protobuf::Map{::String =\\\u003e ::String}) --- Custom labels to apply to the job and any Cloud Logging [LogEntry](https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry) that it generates.\n\n\n Use labels to group and describe the resources they are applied to. Batch\n automatically applies predefined labels and supports multiple `labels`\n fields for each job, which each let you apply custom labels to various\n resources. Label names that start with \"goog-\" or \"google-\" are\n reserved for predefined labels. For more information about labels with\n Batch, see\n [Organize resources using\n labels](https://cloud.google.com/batch/docs/organize-resources-using-labels).\n\n### #logs_policy\n\n def logs_policy() -\u003e ::Google::Cloud::Batch::V1::LogsPolicy\n\n**Returns**\n\n- ([::Google::Cloud::Batch::V1::LogsPolicy](./Google-Cloud-Batch-V1-LogsPolicy)) --- Log preservation policy for the Job.\n\n### #logs_policy=\n\n def logs_policy=(value) -\u003e ::Google::Cloud::Batch::V1::LogsPolicy\n\n**Parameter**\n\n- **value** ([::Google::Cloud::Batch::V1::LogsPolicy](./Google-Cloud-Batch-V1-LogsPolicy)) --- Log preservation policy for the Job. \n**Returns**\n\n- ([::Google::Cloud::Batch::V1::LogsPolicy](./Google-Cloud-Batch-V1-LogsPolicy)) --- Log preservation policy for the Job.\n\n### #name\n\n def name() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Output only. Job name. For example: \"projects/123456/locations/us-central1/jobs/job01\".\n\n### #notifications\n\n def notifications() -\u003e ::Array\u003c::Google::Cloud::Batch::V1::JobNotification\u003e\n\n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Batch::V1::JobNotification](./Google-Cloud-Batch-V1-JobNotification)\\\u003e) --- Notification configurations.\n\n### #notifications=\n\n def notifications=(value) -\u003e ::Array\u003c::Google::Cloud::Batch::V1::JobNotification\u003e\n\n**Parameter**\n\n- **value** (::Array\\\u003c[::Google::Cloud::Batch::V1::JobNotification](./Google-Cloud-Batch-V1-JobNotification)\\\u003e) --- Notification configurations. \n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Batch::V1::JobNotification](./Google-Cloud-Batch-V1-JobNotification)\\\u003e) --- Notification configurations.\n\n### #priority\n\n def priority() -\u003e ::Integer\n\n**Returns**\n\n- (::Integer) --- Priority of the Job. The valid value range is \\[0, 100). Default value is 0. Higher value indicates higher priority. A job with higher priority value is more likely to run earlier if all other requirements are satisfied.\n\n### #priority=\n\n def priority=(value) -\u003e ::Integer\n\n**Parameter**\n\n- **value** (::Integer) --- Priority of the Job. The valid value range is \\[0, 100). Default value is 0. Higher value indicates higher priority. A job with higher priority value is more likely to run earlier if all other requirements are satisfied. \n**Returns**\n\n- (::Integer) --- Priority of the Job. The valid value range is \\[0, 100). Default value is 0. Higher value indicates higher priority. A job with higher priority value is more likely to run earlier if all other requirements are satisfied.\n\n### #status\n\n def status() -\u003e ::Google::Cloud::Batch::V1::JobStatus\n\n**Returns**\n\n- ([::Google::Cloud::Batch::V1::JobStatus](./Google-Cloud-Batch-V1-JobStatus)) --- Output only. Job status. It is read only for users.\n\n### #task_groups\n\n def task_groups() -\u003e ::Array\u003c::Google::Cloud::Batch::V1::TaskGroup\u003e\n\n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Batch::V1::TaskGroup](./Google-Cloud-Batch-V1-TaskGroup)\\\u003e) --- Required. TaskGroups in the Job. Only one TaskGroup is supported now.\n\n### #task_groups=\n\n def task_groups=(value) -\u003e ::Array\u003c::Google::Cloud::Batch::V1::TaskGroup\u003e\n\n**Parameter**\n\n- **value** (::Array\\\u003c[::Google::Cloud::Batch::V1::TaskGroup](./Google-Cloud-Batch-V1-TaskGroup)\\\u003e) --- Required. TaskGroups in the Job. Only one TaskGroup is supported now. \n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Batch::V1::TaskGroup](./Google-Cloud-Batch-V1-TaskGroup)\\\u003e) --- Required. TaskGroups in the Job. Only one TaskGroup is supported now.\n\n### #uid\n\n def uid() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Output only. A system generated unique ID for the Job.\n\n### #update_time\n\n def update_time() -\u003e ::Google::Protobuf::Timestamp\n\n**Returns**\n\n- ([::Google::Protobuf::Timestamp](./Google-Protobuf-Timestamp)) --- Output only. The last time the Job was updated."]]