Class: Google::Apis::AppengineV1::Version

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

Overview

A Version resource is a specific set of source code and configuration files that are deployed into a service.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Version

Returns a new instance of Version



711
712
713
# File 'generated/google/apis/appengine_v1/classes.rb', line 711

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

Instance Attribute Details

#api_configGoogle::Apis::AppengineV1::ApiConfigHandler

Google Cloud Endpoints (https://cloud.google.com/appengine/docs/python/ endpoints/) configuration for API handlers. Corresponds to the JSON property apiConfig



649
650
651
# File 'generated/google/apis/appengine_v1/classes.rb', line 649

def api_config
  @api_config
end

#automatic_scalingGoogle::Apis::AppengineV1::AutomaticScaling

Automatic scaling is based on request rate, response latencies, and other application metrics. Corresponds to the JSON property automaticScaling



535
536
537
# File 'generated/google/apis/appengine_v1/classes.rb', line 535

def automatic_scaling
  @automatic_scaling
end

#basic_scalingGoogle::Apis::AppengineV1::BasicScaling

A service with basic scaling will create an instance when the application receives a request. The instance will be turned down when the app becomes idle. Basic scaling is ideal for work that is intermittent or driven by user activity. Corresponds to the JSON property basicScaling



543
544
545
# File 'generated/google/apis/appengine_v1/classes.rb', line 543

def basic_scaling
  @basic_scaling
end

#beta_settingsHash<String,String>

Metadata settings that are supplied to this version to enable beta runtime features. Corresponds to the JSON property betaSettings

Returns:

  • (Hash<String,String>)


596
597
598
# File 'generated/google/apis/appengine_v1/classes.rb', line 596

def beta_settings
  @beta_settings
end

#create_timeString

Time that this version was created.@OutputOnly Corresponds to the JSON property createTime

Returns:

  • (String)


618
619
620
# File 'generated/google/apis/appengine_v1/classes.rb', line 618

def create_time
  @create_time
end

#created_byString

Email address of the user who created this version.@OutputOnly Corresponds to the JSON property createdBy

Returns:

  • (String)


613
614
615
# File 'generated/google/apis/appengine_v1/classes.rb', line 613

def created_by
  @created_by
end

#default_expirationString

Duration that static files should be cached by web proxies and browsers. Only applicable if the corresponding StaticFilesHandler (https://cloud.google.com/ appengine/docs/admin-api/reference/rest/v1/apps.services.versions# staticfileshandler) does not specify its own expiration time.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property defaultExpiration

Returns:

  • (String)


664
665
666
# File 'generated/google/apis/appengine_v1/classes.rb', line 664

def default_expiration
  @default_expiration
end

#deploymentGoogle::Apis::AppengineV1::Deployment

Code and application artifacts used to deploy a version to App Engine. Corresponds to the JSON property deployment



694
695
696
# File 'generated/google/apis/appengine_v1/classes.rb', line 694

def deployment
  @deployment
end

#disk_usage_bytesFixnum

Total size in bytes of all the files that are included in this version and curerntly hosted on the App Engine disk.@OutputOnly Corresponds to the JSON property diskUsageBytes

Returns:

  • (Fixnum)


624
625
626
# File 'generated/google/apis/appengine_v1/classes.rb', line 624

def disk_usage_bytes
  @disk_usage_bytes
end

#endpoints_api_serviceGoogle::Apis::AppengineV1::EndpointsApiService

Cloud Endpoints (https://cloud.google.com/endpoints) configuration. The Endpoints API Service provides tooling for serving Open API and gRPC endpoints via an NGINX proxy.The fields here refer to the name and configuration id of a "service" resource in the Service Management API (https://cloud.google.com/ service-management/overview). Corresponds to the JSON property endpointsApiService



709
710
711
# File 'generated/google/apis/appengine_v1/classes.rb', line 709

def endpoints_api_service
  @endpoints_api_service
end

#envString

App Engine execution environment for this version.Defaults to standard. Corresponds to the JSON property env

Returns:

  • (String)


601
602
603
# File 'generated/google/apis/appengine_v1/classes.rb', line 601

def env
  @env
end

#env_variablesHash<String,String>

Environment variables available to the application.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property envVariables

Returns:

  • (Hash<String,String>)


655
656
657
# File 'generated/google/apis/appengine_v1/classes.rb', line 655

def env_variables
  @env_variables
end

#error_handlersArray<Google::Apis::AppengineV1::ErrorHandler>

Custom static error pages. Limited to 10KB per page.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property errorHandlers



637
638
639
# File 'generated/google/apis/appengine_v1/classes.rb', line 637

def error_handlers
  @error_handlers
end

#handlersArray<Google::Apis::AppengineV1::UrlMap>

An ordered list of URL-matching patterns that should be applied to incoming requests. The first matching URL handles the request and other request handlers are not attempted.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property handlers



631
632
633
# File 'generated/google/apis/appengine_v1/classes.rb', line 631

def handlers
  @handlers
end

#health_checkGoogle::Apis::AppengineV1::HealthCheck

Health checking configuration for VM instances. Unhealthy instances are killed and replaced with new instances. Only applicable for instances in App Engine flexible environment. Corresponds to the JSON property healthCheck



671
672
673
# File 'generated/google/apis/appengine_v1/classes.rb', line 671

def health_check
  @health_check
end

#idString

Relative name of the version within the service. Example: v1. Version names can contain only lowercase letters, numbers, or hyphens. Reserved names: " default", "latest", and any name with the prefix "ah-". Corresponds to the JSON property id

Returns:

  • (String)


529
530
531
# File 'generated/google/apis/appengine_v1/classes.rb', line 529

def id
  @id
end

#inbound_servicesArray<String>

Before an application can receive email or XMPP messages, the application must be configured to enable the service. Corresponds to the JSON property inboundServices

Returns:

  • (Array<String>)


555
556
557
# File 'generated/google/apis/appengine_v1/classes.rb', line 555

def inbound_services
  @inbound_services
end

#instance_classString

Instance class that is used to run this version. Valid values are: AutomaticScaling: F1, F2, F4, F4_1G ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1 for AutomaticScaling and B1 for ManualScaling or BasicScaling. Corresponds to the JSON property instanceClass

Returns:

  • (String)


563
564
565
# File 'generated/google/apis/appengine_v1/classes.rb', line 563

def instance_class
  @instance_class
end

#librariesArray<Google::Apis::AppengineV1::Library>

Configuration for third-party Python runtime libraries that are required by the application.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property libraries



643
644
645
# File 'generated/google/apis/appengine_v1/classes.rb', line 643

def libraries
  @libraries
end

#liveness_checkGoogle::Apis::AppengineV1::LivenessCheck

Health checking configuration for VM instances. Unhealthy instances are killed and replaced with new instances. Corresponds to the JSON property livenessCheck



683
684
685
# File 'generated/google/apis/appengine_v1/classes.rb', line 683

def liveness_check
  @liveness_check
end

#manual_scalingGoogle::Apis::AppengineV1::ManualScaling

A service with manual scaling runs continuously, allowing you to perform complex initialization and rely on the state of its memory over time. Corresponds to the JSON property manualScaling



549
550
551
# File 'generated/google/apis/appengine_v1/classes.rb', line 549

def manual_scaling
  @manual_scaling
end

#nameString

Full path to the Version resource in the API. Example: apps/myapp/services/ default/versions/v1.@OutputOnly Corresponds to the JSON property name

Returns:

  • (String)


522
523
524
# File 'generated/google/apis/appengine_v1/classes.rb', line 522

def name
  @name
end

#networkGoogle::Apis::AppengineV1::Network

Extra network settings. Only applicable for VM runtimes. Corresponds to the JSON property network



568
569
570
# File 'generated/google/apis/appengine_v1/classes.rb', line 568

def network
  @network
end

#nobuild_files_regexString

Files that match this pattern will not be built into this version. Only applicable for Go runtimes.Only returned in GET requests if view=FULL is set. Corresponds to the JSON property nobuildFilesRegex

Returns:

  • (String)


689
690
691
# File 'generated/google/apis/appengine_v1/classes.rb', line 689

def nobuild_files_regex
  @nobuild_files_regex
end

#readiness_checkGoogle::Apis::AppengineV1::ReadinessCheck

Readiness checking configuration for VM instances. Unhealthy instances are removed from traffic rotation. Corresponds to the JSON property readinessCheck



677
678
679
# File 'generated/google/apis/appengine_v1/classes.rb', line 677

def readiness_check
  @readiness_check
end

#resourcesGoogle::Apis::AppengineV1::Resources

Machine resources for a version. Corresponds to the JSON property resources



573
574
575
# File 'generated/google/apis/appengine_v1/classes.rb', line 573

def resources
  @resources
end

#runtimeString

Desired runtime. Example: python27. Corresponds to the JSON property runtime

Returns:

  • (String)


578
579
580
# File 'generated/google/apis/appengine_v1/classes.rb', line 578

def runtime
  @runtime
end

#serving_statusString

Current serving status of this version. Only the versions with a SERVING status create instances and can be billed.SERVING_STATUS_UNSPECIFIED is an invalid value. Defaults to SERVING. Corresponds to the JSON property servingStatus

Returns:

  • (String)


608
609
610
# File 'generated/google/apis/appengine_v1/classes.rb', line 608

def serving_status
  @serving_status
end

#threadsafeBoolean Also known as: threadsafe?

Whether multiple requests can be dispatched to this version at once. Corresponds to the JSON property threadsafe

Returns:

  • (Boolean)


583
584
585
# File 'generated/google/apis/appengine_v1/classes.rb', line 583

def threadsafe
  @threadsafe
end

#version_urlString

Serving URL for this version. Example: "https://myversion-dot-myservice-dot- myapp.appspot.com"@OutputOnly Corresponds to the JSON property versionUrl

Returns:

  • (String)


700
701
702
# File 'generated/google/apis/appengine_v1/classes.rb', line 700

def version_url
  @version_url
end

#vmBoolean Also known as: vm?

Whether to deploy this version in a container on a virtual machine. Corresponds to the JSON property vm

Returns:

  • (Boolean)


589
590
591
# File 'generated/google/apis/appengine_v1/classes.rb', line 589

def vm
  @vm
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
# File 'generated/google/apis/appengine_v1/classes.rb', line 716

def update!(**args)
  @name = args[:name] if args.key?(:name)
  @id = args[:id] if args.key?(:id)
  @automatic_scaling = args[:automatic_scaling] if args.key?(:automatic_scaling)
  @basic_scaling = args[:basic_scaling] if args.key?(:basic_scaling)
  @manual_scaling = args[:manual_scaling] if args.key?(:manual_scaling)
  @inbound_services = args[:inbound_services] if args.key?(:inbound_services)
  @instance_class = args[:instance_class] if args.key?(:instance_class)
  @network = args[:network] if args.key?(:network)
  @resources = args[:resources] if args.key?(:resources)
  @runtime = args[:runtime] if args.key?(:runtime)
  @threadsafe = args[:threadsafe] if args.key?(:threadsafe)
  @vm = args[:vm] if args.key?(:vm)
  @beta_settings = args[:beta_settings] if args.key?(:beta_settings)
  @env = args[:env] if args.key?(:env)
  @serving_status = args[:serving_status] if args.key?(:serving_status)
  @created_by = args[:created_by] if args.key?(:created_by)
  @create_time = args[:create_time] if args.key?(:create_time)
  @disk_usage_bytes = args[:disk_usage_bytes] if args.key?(:disk_usage_bytes)
  @handlers = args[:handlers] if args.key?(:handlers)
  @error_handlers = args[:error_handlers] if args.key?(:error_handlers)
  @libraries = args[:libraries] if args.key?(:libraries)
  @api_config = args[:api_config] if args.key?(:api_config)
  @env_variables = args[:env_variables] if args.key?(:env_variables)
  @default_expiration = args[:default_expiration] if args.key?(:default_expiration)
  @health_check = args[:health_check] if args.key?(:health_check)
  @readiness_check = args[:readiness_check] if args.key?(:readiness_check)
  @liveness_check = args[:liveness_check] if args.key?(:liveness_check)
  @nobuild_files_regex = args[:nobuild_files_regex] if args.key?(:nobuild_files_regex)
  @deployment = args[:deployment] if args.key?(:deployment)
  @version_url = args[:version_url] if args.key?(:version_url)
  @endpoints_api_service = args[:endpoints_api_service] if args.key?(:endpoints_api_service)
end