Reference documentation and code samples for the Compute V1 Client class Operation.
Represents an Operation resource. Google Compute Engine has three Operation resources: * Global
* Regional
* Zonal
You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses. Operations can be global, regional or zonal. - For global operations, use the globalOperations
resource. - For regional operations, use the regionOperations
resource. - For zonal operations, use the zonalOperations
resource. For more information, read Global, Regional, and Zonal Resources.
Generated from protobuf message google.cloud.compute.v1.Operation
Methods
__construct
Constructor.
data
array
Optional. Data for populating the Message object.
↳ client_operation_id
string
[Output Only] The value of requestId
if you provided it in the request. Not present otherwise.
↳ creation_timestamp
string
[Deprecated] This field is deprecated.
↳ description
string
[Output Only] A textual description of the operation, which is set when the operation is created.
↳ end_time
string
[Output Only] The time that this operation was completed. This value is in RFC3339 text format.
↳ error
Google\Cloud\Compute\V1\Error
[Output Only] If errors are generated during processing of the operation, this field will be populated.
↳ http_error_message
string
[Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND
.
↳ http_error_status_code
int
[Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404
means the resource was not found.
↳ id
int|string
[Output Only] The unique identifier for the operation. This identifier is defined by the server.
↳ insert_time
string
[Output Only] The time that this operation was requested. This value is in RFC3339 text format.
↳ kind
string
[Output Only] Type of the resource. Always compute#operation
for Operation resources.
↳ name
string
[Output Only] Name of the operation.
↳ operation_group_id
string
[Output Only] An ID that represents a group of operations, such as when a group of operations results from a bulkInsert
API request.
↳ operation_type
string
[Output Only] The type of operation, such as insert
, update
, or delete
, and so on.
↳ progress
int
[Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
↳ region
string
[Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
↳ self_link
string
[Output Only] Server-defined URL for the resource.
↳ start_time
string
[Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
↳ status
int
[Output Only] The status of the operation, which can be one of the following: PENDING
, RUNNING
, or DONE
.
↳ status_message
string
[Output Only] An optional textual description of the current status of the operation.
↳ target_id
int|string
[Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
↳ target_link
string
[Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
↳ user
string
[Output Only] User who requested the operation, for example: user@example.com
.
↳ warnings
array< Google\Cloud\Compute\V1\Warnings
>
[Output Only] If warning messages are generated during processing of the operation, this field will be populated.
↳ zone
string
[Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
getClientOperationId
[Output Only] The value of requestId
if you provided it in the request. Not present otherwise.
Generated from protobuf field optional string client_operation_id = 297240295;
string
hasClientOperationId
clearClientOperationId
setClientOperationId
[Output Only] The value of requestId
if you provided it in the request. Not present otherwise.
Generated from protobuf field optional string client_operation_id = 297240295;
var
string
$this
getCreationTimestamp
[Deprecated] This field is deprecated.
Generated from protobuf field optional string creation_timestamp = 30525366;
string
hasCreationTimestamp
clearCreationTimestamp
setCreationTimestamp
[Deprecated] This field is deprecated.
Generated from protobuf field optional string creation_timestamp = 30525366;
var
string
$this
getDescription
[Output Only] A textual description of the operation, which is set when the operation is created.
Generated from protobuf field optional string description = 422937596;
string
hasDescription
clearDescription
setDescription
[Output Only] A textual description of the operation, which is set when the operation is created.
Generated from protobuf field optional string description = 422937596;
var
string
$this
getEndTime
[Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Generated from protobuf field optional string end_time = 114938801;
string
hasEndTime
clearEndTime
setEndTime
[Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Generated from protobuf field optional string end_time = 114938801;
var
string
$this
getError
[Output Only] If errors are generated during processing of the operation, this field will be populated.
Generated from protobuf field optional .google.cloud.compute.v1.Error error = 96784904;
hasError
clearError
setError
[Output Only] If errors are generated during processing of the operation, this field will be populated.
Generated from protobuf field optional .google.cloud.compute.v1.Error error = 96784904;
$this
getHttpErrorMessage
[Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND
.
Generated from protobuf field optional string http_error_message = 202521945 [(.google.cloud.operation_field) = ERROR_MESSAGE];
string
hasHttpErrorMessage
clearHttpErrorMessage
setHttpErrorMessage
[Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND
.
Generated from protobuf field optional string http_error_message = 202521945 [(.google.cloud.operation_field) = ERROR_MESSAGE];
var
string
$this
getHttpErrorStatusCode
[Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404
means the resource was not found.
Generated from protobuf field optional int32 http_error_status_code = 312345196 [(.google.cloud.operation_field) = ERROR_CODE];
int
hasHttpErrorStatusCode
clearHttpErrorStatusCode
setHttpErrorStatusCode
[Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404
means the resource was not found.
Generated from protobuf field optional int32 http_error_status_code = 312345196 [(.google.cloud.operation_field) = ERROR_CODE];
var
int
$this
getId
[Output Only] The unique identifier for the operation. This identifier is defined by the server.
Generated from protobuf field optional uint64 id = 3355;
int|string
hasId
clearId
setId
[Output Only] The unique identifier for the operation. This identifier is defined by the server.
Generated from protobuf field optional uint64 id = 3355;
var
int|string
$this
getInsertTime
[Output Only] The time that this operation was requested. This value is in RFC3339 text format.
Generated from protobuf field optional string insert_time = 433722515;
string
hasInsertTime
clearInsertTime
setInsertTime
[Output Only] The time that this operation was requested. This value is in RFC3339 text format.
Generated from protobuf field optional string insert_time = 433722515;
var
string
$this
getKind
[Output Only] Type of the resource. Always compute#operation
for Operation resources.
Generated from protobuf field optional string kind = 3292052;
string
hasKind
clearKind
setKind
[Output Only] Type of the resource. Always compute#operation
for Operation resources.
Generated from protobuf field optional string kind = 3292052;
var
string
$this
getName
[Output Only] Name of the operation.
Generated from protobuf field optional string name = 3373707 [(.google.cloud.operation_field) = NAME];
string
hasName
clearName
setName
[Output Only] Name of the operation.
Generated from protobuf field optional string name = 3373707 [(.google.cloud.operation_field) = NAME];
var
string
$this
getOperationGroupId
[Output Only] An ID that represents a group of operations, such as when a group of operations results from a bulkInsert
API request.
Generated from protobuf field optional string operation_group_id = 40171187;
string
hasOperationGroupId
clearOperationGroupId
setOperationGroupId
[Output Only] An ID that represents a group of operations, such as when a group of operations results from a bulkInsert
API request.
Generated from protobuf field optional string operation_group_id = 40171187;
var
string
$this
getOperationType
[Output Only] The type of operation, such as insert
, update
, or delete
, and so on.
Generated from protobuf field optional string operation_type = 177650450;
string
hasOperationType
clearOperationType
setOperationType
[Output Only] The type of operation, such as insert
, update
, or delete
, and so on.
Generated from protobuf field optional string operation_type = 177650450;
var
string
$this
getProgress
[Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
Generated from protobuf field optional int32 progress = 72663597;
int
hasProgress
clearProgress
setProgress
[Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
Generated from protobuf field optional int32 progress = 72663597;
var
int
$this
getRegion
[Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
Generated from protobuf field optional string region = 138946292;
string
hasRegion
clearRegion
setRegion
[Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations.
Generated from protobuf field optional string region = 138946292;
var
string
$this
getSelfLink
[Output Only] Server-defined URL for the resource.
Generated from protobuf field optional string self_link = 456214797;
string
hasSelfLink
clearSelfLink
setSelfLink
[Output Only] Server-defined URL for the resource.
Generated from protobuf field optional string self_link = 456214797;
var
string
$this
getStartTime
[Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
Generated from protobuf field optional string start_time = 37467274;
string
hasStartTime
clearStartTime
setStartTime
[Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
Generated from protobuf field optional string start_time = 37467274;
var
string
$this
getStatus
[Output Only] The status of the operation, which can be one of the following: PENDING
, RUNNING
, or DONE
.
Generated from protobuf field optional .google.cloud.compute.v1.Operation.Status status = 181260274 [(.google.cloud.operation_field) = STATUS];
int
hasStatus
clearStatus
setStatus
[Output Only] The status of the operation, which can be one of the following: PENDING
, RUNNING
, or DONE
.
Generated from protobuf field optional .google.cloud.compute.v1.Operation.Status status = 181260274 [(.google.cloud.operation_field) = STATUS];
var
int
$this
getStatusMessage
[Output Only] An optional textual description of the current status of the operation.
Generated from protobuf field optional string status_message = 297428154;
string
hasStatusMessage
clearStatusMessage
setStatusMessage
[Output Only] An optional textual description of the current status of the operation.
Generated from protobuf field optional string status_message = 297428154;
var
string
$this
getTargetId
[Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
Generated from protobuf field optional uint64 target_id = 258165385;
int|string
hasTargetId
clearTargetId
setTargetId
[Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
Generated from protobuf field optional uint64 target_id = 258165385;
var
int|string
$this
getTargetLink
[Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
Generated from protobuf field optional string target_link = 62671336;
string
hasTargetLink
clearTargetLink
setTargetLink
[Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from.
Generated from protobuf field optional string target_link = 62671336;
var
string
$this
getUser
[Output Only] User who requested the operation, for example: user@example.com
.
Generated from protobuf field optional string user = 3599307;
string
hasUser
clearUser
setUser
[Output Only] User who requested the operation, for example: user@example.com
.
Generated from protobuf field optional string user = 3599307;
var
string
$this
getWarnings
[Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Generated from protobuf field repeated .google.cloud.compute.v1.Warnings warnings = 498091095;
Google\Protobuf\Internal\RepeatedField
setWarnings
[Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Generated from protobuf field repeated .google.cloud.compute.v1.Warnings warnings = 498091095;
$this
getZone
[Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Generated from protobuf field optional string zone = 3744684;
string
hasZone
clearZone
setZone
[Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations.
Generated from protobuf field optional string zone = 3744684;
var
string
$this