Operation class final
Represents an Operation resource.
Google Compute Engine has three Operation resources:
You can use an operation resource to manage asynchronous API requests. For more information, readHandling API responses.
Operations can be global, regional or zonal.
- For global operations, use the
globalOperationsresource. - For regional operations, use the
regionOperationsresource. - For zonal operations, use
the
zoneOperationsresource.
For more information, read Global, Regional, and Zonal Resources.
Note that completed Operation resources have a limited retention period.
Constructors
-
Operation({String? clientOperationId, String? creationTimestamp, String? description, String? endTime, Error? error, GetVersionOperationMetadata? getVersionOperationMetadata, String? httpErrorMessage, int? httpErrorStatusCode, BigInt? id, String? insertTime, InstancesBulkInsertOperationMetadata? instancesBulkInsertOperationMetadata, String? kind, String? name, String? operationGroupId, String? operationType, int? progress, String? region, String? selfLink, SetCommonInstanceMetadataOperationMetadata? setCommonInstanceMetadataOperationMetadata, String? startTime, Operation_Status? status, String? statusMessage, BigInt? targetId, String? targetLink, String? user, List<
Warnings> warnings = const [], String? zone}) - Operation.fromJson(Object? j)
-
factory
Properties
- clientOperationId → String?
-
Output OnlyThe value ofrequestIdif you provided it in the request. Not present otherwise.final - creationTimestamp → String?
-
Deprecated This field is deprecated.
final
- description → String?
-
Output OnlyA textual description of the operation, which is set when the operation is created.final - endTime → String?
-
Output OnlyThe time that this operation was completed. This value is inRFC3339 text format.final - error → Error?
-
Output OnlyIf errors are generated during processing of the operation, this field will be populated.final - getVersionOperationMetadata → GetVersionOperationMetadata?
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- httpErrorMessage → String?
-
Output OnlyIf the operation fails, this field contains the HTTP error message that was returned, such asNOT FOUND.final - httpErrorStatusCode → int?
-
Output OnlyIf the operation fails, this field contains the HTTP error status code that was returned. For example, a404means the resource was not found.final - id → BigInt?
-
Output OnlyThe unique identifier for the operation. This identifier is defined by the server.final - insertTime → String?
-
Output OnlyThe time that this operation was requested. This value is inRFC3339 text format.final - instancesBulkInsertOperationMetadata → InstancesBulkInsertOperationMetadata?
-
final
- kind → String?
-
Output only.
Output OnlyType of the resource. Alwayscompute#operationfor Operation resources.final - name → String?
-
Output OnlyName of the operation.final - operationGroupId → String?
-
Output only.
Output OnlyAn ID that represents a group of operations, such as when a group of operations results from abulkInsertAPI request.final - operationType → String?
-
Output OnlyThe type of operation, such asinsert,update, ordelete, and so on.final - progress → int?
-
Output OnlyAn 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.final - qualifiedName → String
-
The fully qualified name of this message, i.e.,
google.protobuf.Durationorgoogle.rpc.ErrorInfo.finalinherited - region → String?
-
Output OnlyThe URL of the region where the operation resides. Only applicable when performing regional operations.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- selfLink → String?
-
Output OnlyServer-defined URL for the resource.final - setCommonInstanceMetadataOperationMetadata → SetCommonInstanceMetadataOperationMetadata?
-
Output only.
Output OnlyIf the operation is for projects.setCommonInstanceMetadata, this field will contain information on all underlying zonal actions and their state.final - startTime → String?
-
Output OnlyThe time that this operation was started by the server. This value is inRFC3339 text format.final - status → Operation_Status?
-
Output OnlyThe status of the operation, which can be one of the following:PENDING,RUNNING, orDONE.final - statusMessage → String?
-
Output OnlyAn optional textual description of the current status of the operation.final - targetId → BigInt?
-
Output OnlyThe unique target ID, which identifies a specific incarnation of the target resource.final - targetLink → String?
-
Output OnlyThe URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the disk that the snapshot was created from.final - user → String?
-
Output OnlyUser who requested the operation, for example:user@example.comoralice_smith_identifier (global/workforcePools/example-com-us-employees).final -
warnings
→ List<
Warnings> -
Output OnlyIf warning messages are generated during processing of the operation, this field will be populated.final - zone → String?
-
Output OnlyThe URL of the zone where the operation resides. Only applicable when performing per-zone operations.final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Object -
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- fullyQualifiedName → const String