google-cloud-orchestration-airflow-service-v1 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a8c779ef4e48955daae1fbf8fa52fc979b3f4f10efdec8df9c2f35912da327f3
4
- data.tar.gz: f51e6e5da1e50b0e889473ba8a80a152ed1e71749a348c92fa3c8d9bf2d3b22a
3
+ metadata.gz: bfdb424292c7f6e1222319ccf539927ae968ea874d1599d7e3ba026d02c19891
4
+ data.tar.gz: 449bf312d93be8a7395562153056c0f81ead2c7dea8decb32a011d1217009ebd
5
5
  SHA512:
6
- metadata.gz: 57c651bca41a62ac151b6491cc03cfe86b8b1811e3afe692d6b812870513bed1119da741dc4a769b8776787dd330046cde4d9aff2026b86637b3bf64ae0891e3
7
- data.tar.gz: 82b4d353aa144d664f986b228ba993c01f3e7451369f950eb0d9c76f3ca10cb74a746abad9a1633b6333a9dfdfeff72e3eeb1c61e230e23b70bb052cbd48b732
6
+ metadata.gz: 967b5d5e4d207f2d1074f7f7973ab9b0aae80638ed5fafdc686caf49a912ffd617acb13119b420a987e9488264850acc5dcc63b19cad8d9e8cab570fbfaf3452
7
+ data.tar.gz: 6d9240969f5a4f4419f5cf35e6b53f8574d4fa5d3e6d393249a293f67cd7dfac8a6b6a3c3fe9d4e3b6011560df58ef8dbef63fb2e74c9a6d9095e75f381e40ed
data/AUTHENTICATION.md CHANGED
@@ -112,7 +112,7 @@ credentials are discovered.
112
112
  To configure your system for this, simply:
113
113
 
114
114
  1. [Download and install the Cloud SDK](https://cloud.google.com/sdk)
115
- 2. Authenticate using OAuth 2.0 `$ gcloud auth login`
115
+ 2. Authenticate using OAuth 2.0 `$ gcloud auth application-default login`
116
116
  3. Write code as if already authenticated.
117
117
 
118
118
  **NOTE:** This is _not_ recommended for running in production. The Cloud SDK
data/README.md CHANGED
@@ -46,7 +46,7 @@ for general usage information.
46
46
  ## Enabling Logging
47
47
 
48
48
  To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
49
- The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib/libdoc/logger/rdoc/Logger.html) as shown below,
49
+ The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/current/stdlibs/logger/Logger.html) as shown below,
50
50
  or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
51
51
  that will write logs to [Cloud Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
52
52
  and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
@@ -549,13 +549,10 @@ module Google
549
549
  # * `config.nodeCount`
550
550
  # * Horizontally scale the number of nodes in the environment. An integer
551
551
  # greater than or equal to 3 must be provided in the `config.nodeCount`
552
- # field.
552
+ # field. Supported for Cloud Composer environments in versions
553
+ # composer-1.*.*-airflow-*.*.*.
553
554
  # * `config.webServerNetworkAccessControl`
554
555
  # * Replace the environment's current `WebServerNetworkAccessControl`.
555
- # * `config.databaseConfig`
556
- # * Replace the environment's current `DatabaseConfig`.
557
- # * `config.webServerConfig`
558
- # * Replace the environment's current `WebServerConfig`.
559
556
  # * `config.softwareConfig.airflowConfigOverrides`
560
557
  # * Replace all Apache Airflow config overrides. If a replacement config
561
558
  # overrides map is not included in `environment`, all config overrides
@@ -573,9 +570,22 @@ module Google
573
570
  # * `config.softwareConfig.envVariables`
574
571
  # * Replace all environment variables. If a replacement environment
575
572
  # variable map is not included in `environment`, all custom environment
576
- # variables are cleared.
577
- # It is an error to provide both this mask and a mask specifying one or
578
- # more individual environment variables.
573
+ # variables are cleared.
574
+ # * `config.softwareConfig.schedulerCount`
575
+ # * Horizontally scale the number of schedulers in Airflow. A positive
576
+ # integer not greater than the number of nodes must be provided in the
577
+ # `config.softwareConfig.schedulerCount` field. Supported for Cloud
578
+ # Composer environments in versions composer-1.*.*-airflow-2.*.*.
579
+ # * `config.databaseConfig.machineType`
580
+ # * Cloud SQL machine type used by Airflow database.
581
+ # It has to be one of: db-n1-standard-2, db-n1-standard-4,
582
+ # db-n1-standard-8 or db-n1-standard-16. Supported for Cloud Composer
583
+ # environments in versions composer-1.*.*-airflow-*.*.*.
584
+ # * `config.webServerConfig.machineType`
585
+ # * Machine type on which Airflow web server is running.
586
+ # It has to be one of: composer-n1-webserver-2, composer-n1-webserver-4
587
+ # or composer-n1-webserver-8. Supported for Cloud Composer environments
588
+ # in versions composer-1.*.*-airflow-*.*.*.
579
589
  #
580
590
  # @yield [response, operation] Access the result along with the RPC operation
581
591
  # @yieldparam response [::Gapic::Operation]
@@ -743,6 +753,218 @@ module Google
743
753
  raise ::Google::Cloud::Error.from_error(e)
744
754
  end
745
755
 
756
+ ##
757
+ # Creates a snapshots of a Cloud Composer environment.
758
+ #
759
+ # As a result of this operation, snapshot of environment's state is stored
760
+ # in a location specified in the SaveSnapshotRequest.
761
+ #
762
+ # @overload save_snapshot(request, options = nil)
763
+ # Pass arguments to `save_snapshot` via a request object, either of type
764
+ # {::Google::Cloud::Orchestration::Airflow::Service::V1::SaveSnapshotRequest} or an equivalent Hash.
765
+ #
766
+ # @param request [::Google::Cloud::Orchestration::Airflow::Service::V1::SaveSnapshotRequest, ::Hash]
767
+ # A request object representing the call parameters. Required. To specify no
768
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
769
+ # @param options [::Gapic::CallOptions, ::Hash]
770
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
771
+ #
772
+ # @overload save_snapshot(environment: nil, snapshot_location: nil)
773
+ # Pass arguments to `save_snapshot` via keyword arguments. Note that at
774
+ # least one keyword argument is required. To specify no parameters, or to keep all
775
+ # the default parameter values, pass an empty Hash as a request object (see above).
776
+ #
777
+ # @param environment [::String]
778
+ # The resource name of the source environment in the form:
779
+ # "projects/\\{projectId}/locations/\\{locationId}/environments/\\{environmentId}"
780
+ # @param snapshot_location [::String]
781
+ # Location in a Cloud Storage where the snapshot is going to be stored, e.g.:
782
+ # "gs://my-bucket/snapshots".
783
+ #
784
+ # @yield [response, operation] Access the result along with the RPC operation
785
+ # @yieldparam response [::Gapic::Operation]
786
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
787
+ #
788
+ # @return [::Gapic::Operation]
789
+ #
790
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
791
+ #
792
+ # @example Basic example
793
+ # require "google/cloud/orchestration/airflow/service/v1"
794
+ #
795
+ # # Create a client object. The client can be reused for multiple calls.
796
+ # client = Google::Cloud::Orchestration::Airflow::Service::V1::Environments::Client.new
797
+ #
798
+ # # Create a request. To set request fields, pass in keyword arguments.
799
+ # request = Google::Cloud::Orchestration::Airflow::Service::V1::SaveSnapshotRequest.new
800
+ #
801
+ # # Call the save_snapshot method.
802
+ # result = client.save_snapshot request
803
+ #
804
+ # # The returned object is of type Gapic::Operation. You can use this
805
+ # # object to check the status of an operation, cancel it, or wait
806
+ # # for results. Here is how to block until completion:
807
+ # result.wait_until_done! timeout: 60
808
+ # if result.response?
809
+ # p result.response
810
+ # else
811
+ # puts "Error!"
812
+ # end
813
+ #
814
+ def save_snapshot request, options = nil
815
+ raise ::ArgumentError, "request must be provided" if request.nil?
816
+
817
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Orchestration::Airflow::Service::V1::SaveSnapshotRequest
818
+
819
+ # Converts hash and nil to an options object
820
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
821
+
822
+ # Customize the options with defaults
823
+ metadata = @config.rpcs.save_snapshot.metadata.to_h
824
+
825
+ # Set x-goog-api-client and x-goog-user-project headers
826
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
827
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
828
+ gapic_version: ::Google::Cloud::Orchestration::Airflow::Service::V1::VERSION
829
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
830
+
831
+ header_params = {}
832
+ if request.environment
833
+ header_params["environment"] = request.environment
834
+ end
835
+
836
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
837
+ metadata[:"x-goog-request-params"] ||= request_params_header
838
+
839
+ options.apply_defaults timeout: @config.rpcs.save_snapshot.timeout,
840
+ metadata: metadata,
841
+ retry_policy: @config.rpcs.save_snapshot.retry_policy
842
+
843
+ options.apply_defaults timeout: @config.timeout,
844
+ metadata: @config.metadata,
845
+ retry_policy: @config.retry_policy
846
+
847
+ @environments_stub.call_rpc :save_snapshot, request, options: options do |response, operation|
848
+ response = ::Gapic::Operation.new response, @operations_client, options: options
849
+ yield response, operation if block_given?
850
+ return response
851
+ end
852
+ rescue ::GRPC::BadStatus => e
853
+ raise ::Google::Cloud::Error.from_error(e)
854
+ end
855
+
856
+ ##
857
+ # Loads a snapshot of a Cloud Composer environment.
858
+ #
859
+ # As a result of this operation, a snapshot of environment's specified in
860
+ # LoadSnapshotRequest is loaded into the environment.
861
+ #
862
+ # @overload load_snapshot(request, options = nil)
863
+ # Pass arguments to `load_snapshot` via a request object, either of type
864
+ # {::Google::Cloud::Orchestration::Airflow::Service::V1::LoadSnapshotRequest} or an equivalent Hash.
865
+ #
866
+ # @param request [::Google::Cloud::Orchestration::Airflow::Service::V1::LoadSnapshotRequest, ::Hash]
867
+ # A request object representing the call parameters. Required. To specify no
868
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
869
+ # @param options [::Gapic::CallOptions, ::Hash]
870
+ # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
871
+ #
872
+ # @overload load_snapshot(environment: nil, snapshot_path: nil, skip_pypi_packages_installation: nil, skip_environment_variables_setting: nil, skip_airflow_overrides_setting: nil, skip_gcs_data_copying: nil)
873
+ # Pass arguments to `load_snapshot` via keyword arguments. Note that at
874
+ # least one keyword argument is required. To specify no parameters, or to keep all
875
+ # the default parameter values, pass an empty Hash as a request object (see above).
876
+ #
877
+ # @param environment [::String]
878
+ # The resource name of the target environment in the form:
879
+ # "projects/\\{projectId}/locations/\\{locationId}/environments/\\{environmentId}"
880
+ # @param snapshot_path [::String]
881
+ # A Cloud Storage path to a snapshot to load, e.g.:
882
+ # "gs://my-bucket/snapshots/project_location_environment_timestamp".
883
+ # @param skip_pypi_packages_installation [::Boolean]
884
+ # Whether or not to skip installing Pypi packages when loading the
885
+ # environment's state.
886
+ # @param skip_environment_variables_setting [::Boolean]
887
+ # Whether or not to skip setting environment variables when loading the
888
+ # environment's state.
889
+ # @param skip_airflow_overrides_setting [::Boolean]
890
+ # Whether or not to skip setting Airflow overrides when loading the
891
+ # environment's state.
892
+ # @param skip_gcs_data_copying [::Boolean]
893
+ # Whether or not to skip copying Cloud Storage data when loading the
894
+ # environment's state.
895
+ #
896
+ # @yield [response, operation] Access the result along with the RPC operation
897
+ # @yieldparam response [::Gapic::Operation]
898
+ # @yieldparam operation [::GRPC::ActiveCall::Operation]
899
+ #
900
+ # @return [::Gapic::Operation]
901
+ #
902
+ # @raise [::Google::Cloud::Error] if the RPC is aborted.
903
+ #
904
+ # @example Basic example
905
+ # require "google/cloud/orchestration/airflow/service/v1"
906
+ #
907
+ # # Create a client object. The client can be reused for multiple calls.
908
+ # client = Google::Cloud::Orchestration::Airflow::Service::V1::Environments::Client.new
909
+ #
910
+ # # Create a request. To set request fields, pass in keyword arguments.
911
+ # request = Google::Cloud::Orchestration::Airflow::Service::V1::LoadSnapshotRequest.new
912
+ #
913
+ # # Call the load_snapshot method.
914
+ # result = client.load_snapshot request
915
+ #
916
+ # # The returned object is of type Gapic::Operation. You can use this
917
+ # # object to check the status of an operation, cancel it, or wait
918
+ # # for results. Here is how to block until completion:
919
+ # result.wait_until_done! timeout: 60
920
+ # if result.response?
921
+ # p result.response
922
+ # else
923
+ # puts "Error!"
924
+ # end
925
+ #
926
+ def load_snapshot request, options = nil
927
+ raise ::ArgumentError, "request must be provided" if request.nil?
928
+
929
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Orchestration::Airflow::Service::V1::LoadSnapshotRequest
930
+
931
+ # Converts hash and nil to an options object
932
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
933
+
934
+ # Customize the options with defaults
935
+ metadata = @config.rpcs.load_snapshot.metadata.to_h
936
+
937
+ # Set x-goog-api-client and x-goog-user-project headers
938
+ metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
939
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
940
+ gapic_version: ::Google::Cloud::Orchestration::Airflow::Service::V1::VERSION
941
+ metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
942
+
943
+ header_params = {}
944
+ if request.environment
945
+ header_params["environment"] = request.environment
946
+ end
947
+
948
+ request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
949
+ metadata[:"x-goog-request-params"] ||= request_params_header
950
+
951
+ options.apply_defaults timeout: @config.rpcs.load_snapshot.timeout,
952
+ metadata: metadata,
953
+ retry_policy: @config.rpcs.load_snapshot.retry_policy
954
+
955
+ options.apply_defaults timeout: @config.timeout,
956
+ metadata: @config.metadata,
957
+ retry_policy: @config.retry_policy
958
+
959
+ @environments_stub.call_rpc :load_snapshot, request, options: options do |response, operation|
960
+ response = ::Gapic::Operation.new response, @operations_client, options: options
961
+ yield response, operation if block_given?
962
+ return response
963
+ end
964
+ rescue ::GRPC::BadStatus => e
965
+ raise ::Google::Cloud::Error.from_error(e)
966
+ end
967
+
746
968
  ##
747
969
  # Configuration class for the Environments API.
748
970
  #
@@ -903,6 +1125,16 @@ module Google
903
1125
  # @return [::Gapic::Config::Method]
904
1126
  #
905
1127
  attr_reader :delete_environment
1128
+ ##
1129
+ # RPC-specific configuration for `save_snapshot`
1130
+ # @return [::Gapic::Config::Method]
1131
+ #
1132
+ attr_reader :save_snapshot
1133
+ ##
1134
+ # RPC-specific configuration for `load_snapshot`
1135
+ # @return [::Gapic::Config::Method]
1136
+ #
1137
+ attr_reader :load_snapshot
906
1138
 
907
1139
  # @private
908
1140
  def initialize parent_rpcs = nil
@@ -916,6 +1148,10 @@ module Google
916
1148
  @update_environment = ::Gapic::Config::Method.new update_environment_config
917
1149
  delete_environment_config = parent_rpcs.delete_environment if parent_rpcs.respond_to? :delete_environment
918
1150
  @delete_environment = ::Gapic::Config::Method.new delete_environment_config
1151
+ save_snapshot_config = parent_rpcs.save_snapshot if parent_rpcs.respond_to? :save_snapshot
1152
+ @save_snapshot = ::Gapic::Config::Method.new save_snapshot_config
1153
+ load_snapshot_config = parent_rpcs.load_snapshot if parent_rpcs.respond_to? :load_snapshot
1154
+ @load_snapshot = ::Gapic::Config::Method.new load_snapshot_config
919
1155
 
920
1156
  yield self if block_given?
921
1157
  end
@@ -37,6 +37,23 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
37
37
  optional :environment, :message, 1, "google.cloud.orchestration.airflow.service.v1.Environment"
38
38
  optional :update_mask, :message, 3, "google.protobuf.FieldMask"
39
39
  end
40
+ add_message "google.cloud.orchestration.airflow.service.v1.SaveSnapshotRequest" do
41
+ optional :environment, :string, 1
42
+ optional :snapshot_location, :string, 2
43
+ end
44
+ add_message "google.cloud.orchestration.airflow.service.v1.SaveSnapshotResponse" do
45
+ optional :snapshot_path, :string, 1
46
+ end
47
+ add_message "google.cloud.orchestration.airflow.service.v1.LoadSnapshotRequest" do
48
+ optional :environment, :string, 1
49
+ optional :snapshot_path, :string, 2
50
+ optional :skip_pypi_packages_installation, :bool, 3
51
+ optional :skip_environment_variables_setting, :bool, 4
52
+ optional :skip_airflow_overrides_setting, :bool, 5
53
+ optional :skip_gcs_data_copying, :bool, 6
54
+ end
55
+ add_message "google.cloud.orchestration.airflow.service.v1.LoadSnapshotResponse" do
56
+ end
40
57
  add_message "google.cloud.orchestration.airflow.service.v1.EnvironmentConfig" do
41
58
  optional :gke_cluster, :string, 1
42
59
  optional :dag_gcs_prefix, :string, 2
@@ -48,7 +65,18 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
48
65
  optional :database_config, :message, 9, "google.cloud.orchestration.airflow.service.v1.DatabaseConfig"
49
66
  optional :web_server_config, :message, 10, "google.cloud.orchestration.airflow.service.v1.WebServerConfig"
50
67
  optional :encryption_config, :message, 11, "google.cloud.orchestration.airflow.service.v1.EncryptionConfig"
68
+ optional :maintenance_window, :message, 12, "google.cloud.orchestration.airflow.service.v1.MaintenanceWindow"
69
+ optional :workloads_config, :message, 15, "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig"
70
+ optional :environment_size, :enum, 16, "google.cloud.orchestration.airflow.service.v1.EnvironmentConfig.EnvironmentSize"
51
71
  optional :airflow_uri, :string, 6
72
+ optional :master_authorized_networks_config, :message, 17, "google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig"
73
+ optional :recovery_config, :message, 18, "google.cloud.orchestration.airflow.service.v1.RecoveryConfig"
74
+ end
75
+ add_enum "google.cloud.orchestration.airflow.service.v1.EnvironmentConfig.EnvironmentSize" do
76
+ value :ENVIRONMENT_SIZE_UNSPECIFIED, 0
77
+ value :ENVIRONMENT_SIZE_SMALL, 1
78
+ value :ENVIRONMENT_SIZE_MEDIUM, 2
79
+ value :ENVIRONMENT_SIZE_LARGE, 3
52
80
  end
53
81
  add_message "google.cloud.orchestration.airflow.service.v1.WebServerNetworkAccessControl" do
54
82
  repeated :allowed_ip_ranges, :message, 1, "google.cloud.orchestration.airflow.service.v1.WebServerNetworkAccessControl.AllowedIpRange"
@@ -66,12 +94,18 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
66
94
  add_message "google.cloud.orchestration.airflow.service.v1.EncryptionConfig" do
67
95
  optional :kms_key_name, :string, 1
68
96
  end
97
+ add_message "google.cloud.orchestration.airflow.service.v1.MaintenanceWindow" do
98
+ optional :start_time, :message, 1, "google.protobuf.Timestamp"
99
+ optional :end_time, :message, 2, "google.protobuf.Timestamp"
100
+ optional :recurrence, :string, 3
101
+ end
69
102
  add_message "google.cloud.orchestration.airflow.service.v1.SoftwareConfig" do
70
103
  optional :image_version, :string, 1
71
104
  map :airflow_config_overrides, :string, :string, 2
72
105
  map :pypi_packages, :string, :string, 3
73
106
  map :env_variables, :string, :string, 4
74
107
  optional :python_version, :string, 6
108
+ optional :scheduler_count, :int32, 7
75
109
  end
76
110
  add_message "google.cloud.orchestration.airflow.service.v1.IPAllocationPolicy" do
77
111
  optional :use_ip_aliases, :bool, 1
@@ -94,18 +128,72 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
94
128
  optional :service_account, :string, 7
95
129
  repeated :tags, :string, 8
96
130
  optional :ip_allocation_policy, :message, 9, "google.cloud.orchestration.airflow.service.v1.IPAllocationPolicy"
131
+ optional :enable_ip_masq_agent, :bool, 11
97
132
  end
98
133
  add_message "google.cloud.orchestration.airflow.service.v1.PrivateClusterConfig" do
99
134
  optional :enable_private_endpoint, :bool, 1
100
135
  optional :master_ipv4_cidr_block, :string, 2
101
136
  optional :master_ipv4_reserved_range, :string, 3
102
137
  end
138
+ add_message "google.cloud.orchestration.airflow.service.v1.NetworkingConfig" do
139
+ optional :connection_type, :enum, 1, "google.cloud.orchestration.airflow.service.v1.NetworkingConfig.ConnectionType"
140
+ end
141
+ add_enum "google.cloud.orchestration.airflow.service.v1.NetworkingConfig.ConnectionType" do
142
+ value :CONNECTION_TYPE_UNSPECIFIED, 0
143
+ value :VPC_PEERING, 1
144
+ value :PRIVATE_SERVICE_CONNECT, 2
145
+ end
103
146
  add_message "google.cloud.orchestration.airflow.service.v1.PrivateEnvironmentConfig" do
104
147
  optional :enable_private_environment, :bool, 1
105
148
  optional :private_cluster_config, :message, 2, "google.cloud.orchestration.airflow.service.v1.PrivateClusterConfig"
106
149
  optional :web_server_ipv4_cidr_block, :string, 3
107
150
  optional :cloud_sql_ipv4_cidr_block, :string, 4
108
151
  optional :web_server_ipv4_reserved_range, :string, 5
152
+ optional :cloud_composer_network_ipv4_cidr_block, :string, 7
153
+ optional :cloud_composer_network_ipv4_reserved_range, :string, 8
154
+ optional :enable_privately_used_public_ips, :bool, 6
155
+ optional :cloud_composer_connection_subnetwork, :string, 9
156
+ optional :networking_config, :message, 10, "google.cloud.orchestration.airflow.service.v1.NetworkingConfig"
157
+ end
158
+ add_message "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig" do
159
+ optional :scheduler, :message, 1, "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.SchedulerResource"
160
+ optional :web_server, :message, 2, "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WebServerResource"
161
+ optional :worker, :message, 3, "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WorkerResource"
162
+ end
163
+ add_message "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.SchedulerResource" do
164
+ optional :cpu, :float, 1
165
+ optional :memory_gb, :float, 2
166
+ optional :storage_gb, :float, 3
167
+ optional :count, :int32, 4
168
+ end
169
+ add_message "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WebServerResource" do
170
+ optional :cpu, :float, 1
171
+ optional :memory_gb, :float, 2
172
+ optional :storage_gb, :float, 3
173
+ end
174
+ add_message "google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WorkerResource" do
175
+ optional :cpu, :float, 1
176
+ optional :memory_gb, :float, 2
177
+ optional :storage_gb, :float, 3
178
+ optional :min_count, :int32, 4
179
+ optional :max_count, :int32, 5
180
+ end
181
+ add_message "google.cloud.orchestration.airflow.service.v1.RecoveryConfig" do
182
+ optional :scheduled_snapshots_config, :message, 1, "google.cloud.orchestration.airflow.service.v1.ScheduledSnapshotsConfig"
183
+ end
184
+ add_message "google.cloud.orchestration.airflow.service.v1.ScheduledSnapshotsConfig" do
185
+ optional :enabled, :bool, 1
186
+ optional :snapshot_location, :string, 6
187
+ optional :snapshot_creation_schedule, :string, 3
188
+ optional :time_zone, :string, 5
189
+ end
190
+ add_message "google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig" do
191
+ optional :enabled, :bool, 1
192
+ repeated :cidr_blocks, :message, 2, "google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig.CidrBlock"
193
+ end
194
+ add_message "google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig.CidrBlock" do
195
+ optional :display_name, :string, 1
196
+ optional :cidr_block, :string, 2
109
197
  end
110
198
  add_message "google.cloud.orchestration.airflow.service.v1.Environment" do
111
199
  optional :name, :string, 1
@@ -151,17 +239,33 @@ module Google
151
239
  ListEnvironmentsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.ListEnvironmentsResponse").msgclass
152
240
  DeleteEnvironmentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.DeleteEnvironmentRequest").msgclass
153
241
  UpdateEnvironmentRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.UpdateEnvironmentRequest").msgclass
242
+ SaveSnapshotRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.SaveSnapshotRequest").msgclass
243
+ SaveSnapshotResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.SaveSnapshotResponse").msgclass
244
+ LoadSnapshotRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.LoadSnapshotRequest").msgclass
245
+ LoadSnapshotResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.LoadSnapshotResponse").msgclass
154
246
  EnvironmentConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.EnvironmentConfig").msgclass
247
+ EnvironmentConfig::EnvironmentSize = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.EnvironmentConfig.EnvironmentSize").enummodule
155
248
  WebServerNetworkAccessControl = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WebServerNetworkAccessControl").msgclass
156
249
  WebServerNetworkAccessControl::AllowedIpRange = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WebServerNetworkAccessControl.AllowedIpRange").msgclass
157
250
  DatabaseConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.DatabaseConfig").msgclass
158
251
  WebServerConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WebServerConfig").msgclass
159
252
  EncryptionConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.EncryptionConfig").msgclass
253
+ MaintenanceWindow = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.MaintenanceWindow").msgclass
160
254
  SoftwareConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.SoftwareConfig").msgclass
161
255
  IPAllocationPolicy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.IPAllocationPolicy").msgclass
162
256
  NodeConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.NodeConfig").msgclass
163
257
  PrivateClusterConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.PrivateClusterConfig").msgclass
258
+ NetworkingConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.NetworkingConfig").msgclass
259
+ NetworkingConfig::ConnectionType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.NetworkingConfig.ConnectionType").enummodule
164
260
  PrivateEnvironmentConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.PrivateEnvironmentConfig").msgclass
261
+ WorkloadsConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WorkloadsConfig").msgclass
262
+ WorkloadsConfig::SchedulerResource = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.SchedulerResource").msgclass
263
+ WorkloadsConfig::WebServerResource = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WebServerResource").msgclass
264
+ WorkloadsConfig::WorkerResource = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.WorkloadsConfig.WorkerResource").msgclass
265
+ RecoveryConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.RecoveryConfig").msgclass
266
+ ScheduledSnapshotsConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.ScheduledSnapshotsConfig").msgclass
267
+ MasterAuthorizedNetworksConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig").msgclass
268
+ MasterAuthorizedNetworksConfig::CidrBlock = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.MasterAuthorizedNetworksConfig.CidrBlock").msgclass
165
269
  Environment = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.Environment").msgclass
166
270
  Environment::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.Environment.State").enummodule
167
271
  CheckUpgradeResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.orchestration.airflow.service.v1.CheckUpgradeResponse").msgclass
@@ -45,6 +45,16 @@ module Google
45
45
  rpc :UpdateEnvironment, ::Google::Cloud::Orchestration::Airflow::Service::V1::UpdateEnvironmentRequest, ::Google::Longrunning::Operation
46
46
  # Delete an environment.
47
47
  rpc :DeleteEnvironment, ::Google::Cloud::Orchestration::Airflow::Service::V1::DeleteEnvironmentRequest, ::Google::Longrunning::Operation
48
+ # Creates a snapshots of a Cloud Composer environment.
49
+ #
50
+ # As a result of this operation, snapshot of environment's state is stored
51
+ # in a location specified in the SaveSnapshotRequest.
52
+ rpc :SaveSnapshot, ::Google::Cloud::Orchestration::Airflow::Service::V1::SaveSnapshotRequest, ::Google::Longrunning::Operation
53
+ # Loads a snapshot of a Cloud Composer environment.
54
+ #
55
+ # As a result of this operation, a snapshot of environment's specified in
56
+ # LoadSnapshotRequest is loaded into the environment.
57
+ rpc :LoadSnapshot, ::Google::Cloud::Orchestration::Airflow::Service::V1::LoadSnapshotRequest, ::Google::Longrunning::Operation
48
58
  end
49
59
 
50
60
  Stub = Service.rpc_stub_class
@@ -4,7 +4,6 @@
4
4
  require 'google/protobuf'
5
5
 
6
6
  require 'google/protobuf/timestamp_pb'
7
- require 'google/api/annotations_pb'
8
7
 
9
8
  Google::Protobuf::DescriptorPool.generated_pool.build do
10
9
  add_file("google/cloud/orchestration/airflow/service/v1/operations.proto", :syntax => :proto3) do
@@ -30,6 +29,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
30
29
  value :DELETE, 2
31
30
  value :UPDATE, 3
32
31
  value :CHECK, 4
32
+ value :SAVE_SNAPSHOT, 5
33
+ value :LOAD_SNAPSHOT, 6
33
34
  end
34
35
  end
35
36
  end
@@ -23,7 +23,7 @@ module Google
23
23
  module Airflow
24
24
  module Service
25
25
  module V1
26
- VERSION = "0.2.0"
26
+ VERSION = "0.3.0"
27
27
  end
28
28
  end
29
29
  end