# Cloud OS Config V1 API - Class Google::Cloud::OsConfig::V1::PatchJob (v1.9.0)

1.9.0 (latest) 1.8.1 1.7.0 1.6.1 1.5.0 1.4.0 1.3.0 1.2.1 1.1.0 1.0.1 0.16.0 0.15.2 0.14.0 0.13.0 0.12.0 0.11.0 0.10.0 0.9.1 Reference documentation and code samples for the Cloud OS Config V1 API class Google::Cloud::OsConfig::V1::PatchJob.

A high level representation of a patch job that is either in progress
or has completed.


Instance details are not included in the job. To paginate through instance
details, use ListPatchJobInstanceDetails.

<br />

For more information about patch jobs, see
[Creating patch
jobs](https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #create_time

    def create_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Time this patch job was created.

### #create_time=

    def create_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Time this patch job was created.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Time this patch job was created.

### #description

    def description() -> ::String

**Returns**

- (::String) --- Description of the patch job. Length of the description is limited to 1024 characters.

### #description=

    def description=(value) -> ::String

**Parameter**

- **value** (::String) --- Description of the patch job. Length of the description is limited to 1024 characters.
**Returns**

- (::String) --- Description of the patch job. Length of the description is limited to 1024 characters.

### #display_name

    def display_name() -> ::String

**Returns**

- (::String) --- Display name for this patch job. This is not a unique identifier.

### #display_name=

    def display_name=(value) -> ::String

**Parameter**

- **value** (::String) --- Display name for this patch job. This is not a unique identifier.
**Returns**

- (::String) --- Display name for this patch job. This is not a unique identifier.

### #dry_run

    def dry_run() -> ::Boolean

**Returns**

- (::Boolean) --- If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.

### #dry_run=

    def dry_run=(value) -> ::Boolean

**Parameter**

- **value** (::Boolean) --- If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.
**Returns**

- (::Boolean) --- If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.

### #duration

    def duration() -> ::Google::Protobuf::Duration

**Returns**

- ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Duration)) --- Duration of the patch job. After the duration ends, the patch job times out.

### #duration=

    def duration=(value) -> ::Google::Protobuf::Duration

**Parameter**

- **value** ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Duration)) --- Duration of the patch job. After the duration ends, the patch job times out.
**Returns**

- ([::Google::Protobuf::Duration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Duration)) --- Duration of the patch job. After the duration ends, the patch job times out.

### #error_message

    def error_message() -> ::String

**Returns**

- (::String) --- If this patch job failed, this message provides information about the failure.

### #error_message=

    def error_message=(value) -> ::String

**Parameter**

- **value** (::String) --- If this patch job failed, this message provides information about the failure.
**Returns**

- (::String) --- If this patch job failed, this message provides information about the failure.

### #instance_details_summary

    def instance_details_summary() -> ::Google::Cloud::OsConfig::V1::PatchJob::InstanceDetailsSummary

**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchJob::InstanceDetailsSummary](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-InstanceDetailsSummary)) --- Summary of instance details.

### #instance_details_summary=

    def instance_details_summary=(value) -> ::Google::Cloud::OsConfig::V1::PatchJob::InstanceDetailsSummary

**Parameter**

- **value** ([::Google::Cloud::OsConfig::V1::PatchJob::InstanceDetailsSummary](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-InstanceDetailsSummary)) --- Summary of instance details.
**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchJob::InstanceDetailsSummary](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-InstanceDetailsSummary)) --- Summary of instance details.

### #instance_filter

    def instance_filter() -> ::Google::Cloud::OsConfig::V1::PatchInstanceFilter

**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchInstanceFilter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchInstanceFilter)) --- Instances to patch.

### #instance_filter=

    def instance_filter=(value) -> ::Google::Cloud::OsConfig::V1::PatchInstanceFilter

**Parameter**

- **value** ([::Google::Cloud::OsConfig::V1::PatchInstanceFilter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchInstanceFilter)) --- Instances to patch.
**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchInstanceFilter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchInstanceFilter)) --- Instances to patch.

### #name

    def name() -> ::String

**Returns**

- (::String) --- Unique identifier for this patch job in the form `projects/*/patchJobs/*`

### #name=

    def name=(value) -> ::String

**Parameter**

- **value** (::String) --- Unique identifier for this patch job in the form `projects/*/patchJobs/*`
**Returns**

- (::String) --- Unique identifier for this patch job in the form `projects/*/patchJobs/*`

### #patch_config

    def patch_config() -> ::Google::Cloud::OsConfig::V1::PatchConfig

**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchConfig)) --- Patch configuration being applied.

### #patch_config=

    def patch_config=(value) -> ::Google::Cloud::OsConfig::V1::PatchConfig

**Parameter**

- **value** ([::Google::Cloud::OsConfig::V1::PatchConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchConfig)) --- Patch configuration being applied.
**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchConfig)) --- Patch configuration being applied.

### #patch_deployment

    def patch_deployment() -> ::String

**Returns**

- (::String) --- Output only. Name of the patch deployment that created this patch job.

### #percent_complete

    def percent_complete() -> ::Float

**Returns**

- (::Float) --- Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.

### #percent_complete=

    def percent_complete=(value) -> ::Float

**Parameter**

- **value** (::Float) --- Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.
**Returns**

- (::Float) --- Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.

### #rollout

    def rollout() -> ::Google::Cloud::OsConfig::V1::PatchRollout

**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchRollout](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchRollout)) --- Rollout strategy being applied.

### #rollout=

    def rollout=(value) -> ::Google::Cloud::OsConfig::V1::PatchRollout

**Parameter**

- **value** ([::Google::Cloud::OsConfig::V1::PatchRollout](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchRollout)) --- Rollout strategy being applied.
**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchRollout](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchRollout)) --- Rollout strategy being applied.

### #state

    def state() -> ::Google::Cloud::OsConfig::V1::PatchJob::State

**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchJob::State](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-State)) --- The current state of the PatchJob.

### #state=

    def state=(value) -> ::Google::Cloud::OsConfig::V1::PatchJob::State

**Parameter**

- **value** ([::Google::Cloud::OsConfig::V1::PatchJob::State](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-State)) --- The current state of the PatchJob.
**Returns**

- ([::Google::Cloud::OsConfig::V1::PatchJob::State](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Cloud-OsConfig-V1-PatchJob-State)) --- The current state of the PatchJob.

### #update_time

    def update_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Last time this patch job was updated.

### #update_time=

    def update_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Last time this patch job was updated.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-os_config-v1/latest/Google-Protobuf-Timestamp)) --- Last time this patch job was updated.