Class: Google::Apis::ApphubV1alpha::Workload
- Inherits:
-
Object
- Object
- Google::Apis::ApphubV1alpha::Workload
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/apphub_v1alpha/classes.rb,
lib/google/apis/apphub_v1alpha/representations.rb,
lib/google/apis/apphub_v1alpha/representations.rb
Overview
Workload is an App Hub data model that contains a discovered workload, which represents a binary deployment (such as managed instance groups (MIGs) and GKE deployments) that performs the smallest logical subset of business functionality.
Instance Attribute Summary collapse
-
#attributes ⇒ Google::Apis::ApphubV1alpha::Attributes
Consumer provided attributes.
-
#create_time ⇒ String
Output only.
-
#description ⇒ String
Optional.
-
#discovered_workload ⇒ String
Required.
-
#display_name ⇒ String
Optional.
-
#name ⇒ String
Identifier.
-
#state ⇒ String
Output only.
-
#uid ⇒ String
Output only.
-
#update_time ⇒ String
Output only.
-
#workload_properties ⇒ Google::Apis::ApphubV1alpha::WorkloadProperties
Properties of an underlying compute resource represented by the Workload.
-
#workload_reference ⇒ Google::Apis::ApphubV1alpha::WorkloadReference
Reference of an underlying compute resource represented by the Workload.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Workload
constructor
A new instance of Workload.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Workload
Returns a new instance of Workload.
1580 1581 1582 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1580 def initialize(**args) update!(**args) end |
Instance Attribute Details
#attributes ⇒ Google::Apis::ApphubV1alpha::Attributes
Consumer provided attributes.
Corresponds to the JSON property attributes
1526 1527 1528 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1526 def attributes @attributes end |
#create_time ⇒ String
Output only. Create time.
Corresponds to the JSON property createTime
1531 1532 1533 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1531 def create_time @create_time end |
#description ⇒ String
Optional. User-defined description of a Workload.
Corresponds to the JSON property description
1536 1537 1538 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1536 def description @description end |
#discovered_workload ⇒ String
Required. Immutable. The resource name of the original discovered workload.
Corresponds to the JSON property discoveredWorkload
1541 1542 1543 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1541 def discovered_workload @discovered_workload end |
#display_name ⇒ String
Optional. User-defined name for the Workload.
Corresponds to the JSON property displayName
1546 1547 1548 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1546 def display_name @display_name end |
#name ⇒ String
Identifier. The resource name of the Workload. Format: "projects/host-project-
id/locations/location/applications/application-id/workloads/workload-id"
Corresponds to the JSON property name
1552 1553 1554 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1552 def name @name end |
#state ⇒ String
Output only. Workload state.
Corresponds to the JSON property state
1557 1558 1559 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1557 def state @state end |
#uid ⇒ String
Output only. A universally unique identifier (UUID) for the Workload in the
UUID4 format.
Corresponds to the JSON property uid
1563 1564 1565 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1563 def uid @uid end |
#update_time ⇒ String
Output only. Update time.
Corresponds to the JSON property updateTime
1568 1569 1570 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1568 def update_time @update_time end |
#workload_properties ⇒ Google::Apis::ApphubV1alpha::WorkloadProperties
Properties of an underlying compute resource represented by the Workload.
Corresponds to the JSON property workloadProperties
1573 1574 1575 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1573 def workload_properties @workload_properties end |
#workload_reference ⇒ Google::Apis::ApphubV1alpha::WorkloadReference
Reference of an underlying compute resource represented by the Workload.
Corresponds to the JSON property workloadReference
1578 1579 1580 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1578 def workload_reference @workload_reference end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 |
# File 'lib/google/apis/apphub_v1alpha/classes.rb', line 1585 def update!(**args) @attributes = args[:attributes] if args.key?(:attributes) @create_time = args[:create_time] if args.key?(:create_time) @description = args[:description] if args.key?(:description) @discovered_workload = args[:discovered_workload] if args.key?(:discovered_workload) @display_name = args[:display_name] if args.key?(:display_name) @name = args[:name] if args.key?(:name) @state = args[:state] if args.key?(:state) @uid = args[:uid] if args.key?(:uid) @update_time = args[:update_time] if args.key?(:update_time) @workload_properties = args[:workload_properties] if args.key?(:workload_properties) @workload_reference = args[:workload_reference] if args.key?(:workload_reference) end |