Class: Google::Apis::RunV1::Revision

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/run_v1/classes.rb,
lib/google/apis/run_v1/representations.rb,
lib/google/apis/run_v1/representations.rb

Overview

Revision is an immutable snapshot of code and configuration. A revision references one or more container images. Revisions are created by updates to a Service.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Revision

Returns a new instance of Revision.



5175
5176
5177
# File 'lib/google/apis/run_v1/classes.rb', line 5175

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#api_versionString

The API version for this call such as "serving.knative.dev/v1". Corresponds to the JSON property apiVersion

Returns:

  • (String)


5151
5152
5153
# File 'lib/google/apis/run_v1/classes.rb', line 5151

def api_version
  @api_version
end

#kindString

The kind of this resource, in this case "Revision". Corresponds to the JSON property kind

Returns:

  • (String)


5156
5157
5158
# File 'lib/google/apis/run_v1/classes.rb', line 5156

def kind
  @kind
end

#metadataGoogle::Apis::RunV1::ObjectMeta

google.cloud.run.meta.v1.ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create. Corresponds to the JSON property metadata



5162
5163
5164
# File 'lib/google/apis/run_v1/classes.rb', line 5162

def 
  @metadata
end

#specGoogle::Apis::RunV1::RevisionSpec

RevisionSpec holds the desired state of the Revision (from the client). Corresponds to the JSON property spec



5167
5168
5169
# File 'lib/google/apis/run_v1/classes.rb', line 5167

def spec
  @spec
end

#statusGoogle::Apis::RunV1::RevisionStatus

RevisionStatus communicates the observed state of the Revision (from the controller). Corresponds to the JSON property status



5173
5174
5175
# File 'lib/google/apis/run_v1/classes.rb', line 5173

def status
  @status
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5180
5181
5182
5183
5184
5185
5186
# File 'lib/google/apis/run_v1/classes.rb', line 5180

def update!(**args)
  @api_version = args[:api_version] if args.key?(:api_version)
  @kind = args[:kind] if args.key?(:kind)
  @metadata = args[:metadata] if args.key?(:metadata)
  @spec = args[:spec] if args.key?(:spec)
  @status = args[:status] if args.key?(:status)
end