/
classes.rb
6917 lines (5732 loc) · 281 KB
/
classes.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
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
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module DataflowV1b3
# Obsolete in favor of ApproximateReportedProgress and ApproximateSplitRequest.
class ApproximateProgress
include Google::Apis::Core::Hashable
# Obsolete.
# Corresponds to the JSON property `percentComplete`
# @return [Float]
attr_accessor :percent_complete
# Position defines a position within a collection of data. The value can be
# either the end position, a key (used with ordered collections), a byte offset,
# or a record index.
# Corresponds to the JSON property `position`
# @return [Google::Apis::DataflowV1b3::Position]
attr_accessor :position
# Obsolete.
# Corresponds to the JSON property `remainingTime`
# @return [String]
attr_accessor :remaining_time
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@percent_complete = args[:percent_complete] if args.key?(:percent_complete)
@position = args[:position] if args.key?(:position)
@remaining_time = args[:remaining_time] if args.key?(:remaining_time)
end
end
# A progress measurement of a WorkItem by a worker.
class ApproximateReportedProgress
include Google::Apis::Core::Hashable
# Represents the level of parallelism in a WorkItem's input, reported by the
# worker.
# Corresponds to the JSON property `consumedParallelism`
# @return [Google::Apis::DataflowV1b3::ReportedParallelism]
attr_accessor :consumed_parallelism
# Completion as fraction of the input consumed, from 0.0 (beginning, nothing
# consumed), to 1.0 (end of the input, entire input consumed).
# Corresponds to the JSON property `fractionConsumed`
# @return [Float]
attr_accessor :fraction_consumed
# Position defines a position within a collection of data. The value can be
# either the end position, a key (used with ordered collections), a byte offset,
# or a record index.
# Corresponds to the JSON property `position`
# @return [Google::Apis::DataflowV1b3::Position]
attr_accessor :position
# Represents the level of parallelism in a WorkItem's input, reported by the
# worker.
# Corresponds to the JSON property `remainingParallelism`
# @return [Google::Apis::DataflowV1b3::ReportedParallelism]
attr_accessor :remaining_parallelism
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@consumed_parallelism = args[:consumed_parallelism] if args.key?(:consumed_parallelism)
@fraction_consumed = args[:fraction_consumed] if args.key?(:fraction_consumed)
@position = args[:position] if args.key?(:position)
@remaining_parallelism = args[:remaining_parallelism] if args.key?(:remaining_parallelism)
end
end
# A suggestion by the service to the worker to dynamically split the WorkItem.
class ApproximateSplitRequest
include Google::Apis::Core::Hashable
# A fraction at which to split the work item, from 0.0 (beginning of the input)
# to 1.0 (end of the input).
# Corresponds to the JSON property `fractionConsumed`
# @return [Float]
attr_accessor :fraction_consumed
# The fraction of the remainder of work to split the work item at, from 0.0 (
# split at the current position) to 1.0 (end of the input).
# Corresponds to the JSON property `fractionOfRemainder`
# @return [Float]
attr_accessor :fraction_of_remainder
# Position defines a position within a collection of data. The value can be
# either the end position, a key (used with ordered collections), a byte offset,
# or a record index.
# Corresponds to the JSON property `position`
# @return [Google::Apis::DataflowV1b3::Position]
attr_accessor :position
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@fraction_consumed = args[:fraction_consumed] if args.key?(:fraction_consumed)
@fraction_of_remainder = args[:fraction_of_remainder] if args.key?(:fraction_of_remainder)
@position = args[:position] if args.key?(:position)
end
end
# Job information for templates.
class Artifact
include Google::Apis::Core::Hashable
# Container Spec.
# Corresponds to the JSON property `containerSpec`
# @return [Google::Apis::DataflowV1b3::ContainerSpec]
attr_accessor :container_spec
# job_graph_gcs_path set for legacy Template.
# Corresponds to the JSON property `jobGraphGcsPath`
# @return [String]
attr_accessor :job_graph_gcs_path
# Metadata describing a template.
# Corresponds to the JSON property `metadata`
# @return [Google::Apis::DataflowV1b3::TemplateMetadata]
attr_accessor :metadata
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@container_spec = args[:container_spec] if args.key?(:container_spec)
@job_graph_gcs_path = args[:job_graph_gcs_path] if args.key?(:job_graph_gcs_path)
@metadata = args[:metadata] if args.key?(:metadata)
end
end
# A structured message reporting an autoscaling decision made by the Dataflow
# service.
class AutoscalingEvent
include Google::Apis::Core::Hashable
# The current number of workers the job has.
# Corresponds to the JSON property `currentNumWorkers`
# @return [Fixnum]
attr_accessor :current_num_workers
# A rich message format, including a human readable string, a key for
# identifying the message, and structured data associated with the message for
# programmatic consumption.
# Corresponds to the JSON property `description`
# @return [Google::Apis::DataflowV1b3::StructuredMessage]
attr_accessor :description
# The type of autoscaling event to report.
# Corresponds to the JSON property `eventType`
# @return [String]
attr_accessor :event_type
# The target number of workers the worker pool wants to resize to use.
# Corresponds to the JSON property `targetNumWorkers`
# @return [Fixnum]
attr_accessor :target_num_workers
# The time this event was emitted to indicate a new target or current
# num_workers value.
# Corresponds to the JSON property `time`
# @return [String]
attr_accessor :time
# A short and friendly name for the worker pool this event refers to, populated
# from the value of PoolStageRelation::user_pool_name.
# Corresponds to the JSON property `workerPool`
# @return [String]
attr_accessor :worker_pool
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@current_num_workers = args[:current_num_workers] if args.key?(:current_num_workers)
@description = args[:description] if args.key?(:description)
@event_type = args[:event_type] if args.key?(:event_type)
@target_num_workers = args[:target_num_workers] if args.key?(:target_num_workers)
@time = args[:time] if args.key?(:time)
@worker_pool = args[:worker_pool] if args.key?(:worker_pool)
end
end
# Settings for WorkerPool autoscaling.
class AutoscalingSettings
include Google::Apis::Core::Hashable
# The algorithm to use for autoscaling.
# Corresponds to the JSON property `algorithm`
# @return [String]
attr_accessor :algorithm
# The maximum number of workers to cap scaling at.
# Corresponds to the JSON property `maxNumWorkers`
# @return [Fixnum]
attr_accessor :max_num_workers
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@algorithm = args[:algorithm] if args.key?(:algorithm)
@max_num_workers = args[:max_num_workers] if args.key?(:max_num_workers)
end
end
# Metadata for a BigQuery connector used by the job.
class BigQueryIoDetails
include Google::Apis::Core::Hashable
# Dataset accessed in the connection.
# Corresponds to the JSON property `dataset`
# @return [String]
attr_accessor :dataset
# Project accessed in the connection.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# Query used to access data in the connection.
# Corresponds to the JSON property `query`
# @return [String]
attr_accessor :query
# Table accessed in the connection.
# Corresponds to the JSON property `table`
# @return [String]
attr_accessor :table
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@dataset = args[:dataset] if args.key?(:dataset)
@project_id = args[:project_id] if args.key?(:project_id)
@query = args[:query] if args.key?(:query)
@table = args[:table] if args.key?(:table)
end
end
# Metadata for a BigTable connector used by the job.
class BigTableIoDetails
include Google::Apis::Core::Hashable
# InstanceId accessed in the connection.
# Corresponds to the JSON property `instanceId`
# @return [String]
attr_accessor :instance_id
# ProjectId accessed in the connection.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
# TableId accessed in the connection.
# Corresponds to the JSON property `tableId`
# @return [String]
attr_accessor :table_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@instance_id = args[:instance_id] if args.key?(:instance_id)
@project_id = args[:project_id] if args.key?(:project_id)
@table_id = args[:table_id] if args.key?(:table_id)
end
end
# Modeled after information exposed by /proc/stat.
class CpuTime
include Google::Apis::Core::Hashable
# Average CPU utilization rate (% non-idle cpu / second) since previous sample.
# Corresponds to the JSON property `rate`
# @return [Float]
attr_accessor :rate
# Timestamp of the measurement.
# Corresponds to the JSON property `timestamp`
# @return [String]
attr_accessor :timestamp
# Total active CPU time across all cores (ie., non-idle) in milliseconds since
# start-up.
# Corresponds to the JSON property `totalMs`
# @return [Fixnum]
attr_accessor :total_ms
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@rate = args[:rate] if args.key?(:rate)
@timestamp = args[:timestamp] if args.key?(:timestamp)
@total_ms = args[:total_ms] if args.key?(:total_ms)
end
end
# Commit will add a new TemplateVersion to an existing template.
class CommitTemplateVersionRequest
include Google::Apis::Core::Hashable
# ///////////////////////////////////////////////////////////////////////////// /
# /// Template Catalog is used to organize user TemplateVersions. ////
# TemplateVersions that have the same project_id and display_name are ////
# belong to the same Template. //// Templates with the same project_id belong to
# the same Project. //// TemplateVersion may have labels and multiple labels are
# allowed. //// Duplicated labels in the same `TemplateVersion` are not allowed.
# //// TemplateVersion may have tags and multiple tags are allowed. Duplicated //
# // tags in the same `Template` are not allowed!
# Corresponds to the JSON property `templateVersion`
# @return [Google::Apis::DataflowV1b3::TemplateVersion]
attr_accessor :template_version
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@template_version = args[:template_version] if args.key?(:template_version)
end
end
# Description of an interstitial value between transforms in an execution stage.
class ComponentSource
include Google::Apis::Core::Hashable
# Dataflow service generated name for this source.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# User name for the original user transform or collection with which this source
# is most closely associated.
# Corresponds to the JSON property `originalTransformOrCollection`
# @return [String]
attr_accessor :original_transform_or_collection
# Human-readable name for this transform; may be user or system generated.
# Corresponds to the JSON property `userName`
# @return [String]
attr_accessor :user_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@original_transform_or_collection = args[:original_transform_or_collection] if args.key?(:original_transform_or_collection)
@user_name = args[:user_name] if args.key?(:user_name)
end
end
# Description of a transform executed as part of an execution stage.
class ComponentTransform
include Google::Apis::Core::Hashable
# Dataflow service generated name for this source.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# User name for the original user transform with which this transform is most
# closely associated.
# Corresponds to the JSON property `originalTransform`
# @return [String]
attr_accessor :original_transform
# Human-readable name for this transform; may be user or system generated.
# Corresponds to the JSON property `userName`
# @return [String]
attr_accessor :user_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@original_transform = args[:original_transform] if args.key?(:original_transform)
@user_name = args[:user_name] if args.key?(:user_name)
end
end
# All configuration data for a particular Computation.
class ComputationTopology
include Google::Apis::Core::Hashable
# The ID of the computation.
# Corresponds to the JSON property `computationId`
# @return [String]
attr_accessor :computation_id
# The inputs to the computation.
# Corresponds to the JSON property `inputs`
# @return [Array<Google::Apis::DataflowV1b3::StreamLocation>]
attr_accessor :inputs
# The key ranges processed by the computation.
# Corresponds to the JSON property `keyRanges`
# @return [Array<Google::Apis::DataflowV1b3::KeyRangeLocation>]
attr_accessor :key_ranges
# The outputs from the computation.
# Corresponds to the JSON property `outputs`
# @return [Array<Google::Apis::DataflowV1b3::StreamLocation>]
attr_accessor :outputs
# The state family values.
# Corresponds to the JSON property `stateFamilies`
# @return [Array<Google::Apis::DataflowV1b3::StateFamilyConfig>]
attr_accessor :state_families
# The system stage name.
# Corresponds to the JSON property `systemStageName`
# @return [String]
attr_accessor :system_stage_name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@computation_id = args[:computation_id] if args.key?(:computation_id)
@inputs = args[:inputs] if args.key?(:inputs)
@key_ranges = args[:key_ranges] if args.key?(:key_ranges)
@outputs = args[:outputs] if args.key?(:outputs)
@state_families = args[:state_families] if args.key?(:state_families)
@system_stage_name = args[:system_stage_name] if args.key?(:system_stage_name)
end
end
# A position that encapsulates an inner position and an index for the inner
# position. A ConcatPosition can be used by a reader of a source that
# encapsulates a set of other sources.
class ConcatPosition
include Google::Apis::Core::Hashable
# Index of the inner source.
# Corresponds to the JSON property `index`
# @return [Fixnum]
attr_accessor :index
# Position defines a position within a collection of data. The value can be
# either the end position, a key (used with ordered collections), a byte offset,
# or a record index.
# Corresponds to the JSON property `position`
# @return [Google::Apis::DataflowV1b3::Position]
attr_accessor :position
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@index = args[:index] if args.key?(:index)
@position = args[:position] if args.key?(:position)
end
end
# Container Spec.
class ContainerSpec
include Google::Apis::Core::Hashable
# The environment values to be set at runtime for flex template.
# Corresponds to the JSON property `defaultEnvironment`
# @return [Google::Apis::DataflowV1b3::FlexTemplateRuntimeEnvironment]
attr_accessor :default_environment
# Name of the docker container image. E.g., gcr.io/project/some-image
# Corresponds to the JSON property `image`
# @return [String]
attr_accessor :image
# Metadata describing a template.
# Corresponds to the JSON property `metadata`
# @return [Google::Apis::DataflowV1b3::TemplateMetadata]
attr_accessor :metadata
# SDK Information.
# Corresponds to the JSON property `sdkInfo`
# @return [Google::Apis::DataflowV1b3::SdkInfo]
attr_accessor :sdk_info
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@default_environment = args[:default_environment] if args.key?(:default_environment)
@image = args[:image] if args.key?(:image)
@metadata = args[:metadata] if args.key?(:metadata)
@sdk_info = args[:sdk_info] if args.key?(:sdk_info)
end
end
# CounterMetadata includes all static non-name non-value counter attributes.
class CounterMetadata
include Google::Apis::Core::Hashable
# Human-readable description of the counter semantics.
# Corresponds to the JSON property `description`
# @return [String]
attr_accessor :description
# Counter aggregation kind.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind
# A string referring to the unit type.
# Corresponds to the JSON property `otherUnits`
# @return [String]
attr_accessor :other_units
# System defined Units, see above enum.
# Corresponds to the JSON property `standardUnits`
# @return [String]
attr_accessor :standard_units
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@description = args[:description] if args.key?(:description)
@kind = args[:kind] if args.key?(:kind)
@other_units = args[:other_units] if args.key?(:other_units)
@standard_units = args[:standard_units] if args.key?(:standard_units)
end
end
# Identifies a counter within a per-job namespace. Counters whose structured
# names are the same get merged into a single value for the job.
class CounterStructuredName
include Google::Apis::Core::Hashable
# Name of the optimized step being executed by the workers.
# Corresponds to the JSON property `componentStepName`
# @return [String]
attr_accessor :component_step_name
# Name of the stage. An execution step contains multiple component steps.
# Corresponds to the JSON property `executionStepName`
# @return [String]
attr_accessor :execution_step_name
# Index of an input collection that's being read from/written to as a side input.
# The index identifies a step's side inputs starting by 1 (e.g. the first side
# input has input_index 1, the third has input_index 3). Side inputs are
# identified by a pair of (original_step_name, input_index). This field helps
# uniquely identify them.
# Corresponds to the JSON property `inputIndex`
# @return [Fixnum]
attr_accessor :input_index
# Counter name. Not necessarily globally-unique, but unique within the context
# of the other fields. Required.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# One of the standard Origins defined above.
# Corresponds to the JSON property `origin`
# @return [String]
attr_accessor :origin
# A string containing a more specific namespace of the counter's origin.
# Corresponds to the JSON property `originNamespace`
# @return [String]
attr_accessor :origin_namespace
# The step name requesting an operation, such as GBK. I.e. the ParDo causing a
# read/write from shuffle to occur, or a read from side inputs.
# Corresponds to the JSON property `originalRequestingStepName`
# @return [String]
attr_accessor :original_requesting_step_name
# System generated name of the original step in the user's graph, before
# optimization.
# Corresponds to the JSON property `originalStepName`
# @return [String]
attr_accessor :original_step_name
# Portion of this counter, either key or value.
# Corresponds to the JSON property `portion`
# @return [String]
attr_accessor :portion
# ID of a particular worker.
# Corresponds to the JSON property `workerId`
# @return [String]
attr_accessor :worker_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@component_step_name = args[:component_step_name] if args.key?(:component_step_name)
@execution_step_name = args[:execution_step_name] if args.key?(:execution_step_name)
@input_index = args[:input_index] if args.key?(:input_index)
@name = args[:name] if args.key?(:name)
@origin = args[:origin] if args.key?(:origin)
@origin_namespace = args[:origin_namespace] if args.key?(:origin_namespace)
@original_requesting_step_name = args[:original_requesting_step_name] if args.key?(:original_requesting_step_name)
@original_step_name = args[:original_step_name] if args.key?(:original_step_name)
@portion = args[:portion] if args.key?(:portion)
@worker_id = args[:worker_id] if args.key?(:worker_id)
end
end
# A single message which encapsulates structured name and metadata for a given
# counter.
class CounterStructuredNameAndMetadata
include Google::Apis::Core::Hashable
# CounterMetadata includes all static non-name non-value counter attributes.
# Corresponds to the JSON property `metadata`
# @return [Google::Apis::DataflowV1b3::CounterMetadata]
attr_accessor :metadata
# Identifies a counter within a per-job namespace. Counters whose structured
# names are the same get merged into a single value for the job.
# Corresponds to the JSON property `name`
# @return [Google::Apis::DataflowV1b3::CounterStructuredName]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@metadata = args[:metadata] if args.key?(:metadata)
@name = args[:name] if args.key?(:name)
end
end
# An update to a Counter sent from a worker.
class CounterUpdate
include Google::Apis::Core::Hashable
# Boolean value for And, Or.
# Corresponds to the JSON property `boolean`
# @return [Boolean]
attr_accessor :boolean
alias_method :boolean?, :boolean
# True if this counter is reported as the total cumulative aggregate value
# accumulated since the worker started working on this WorkItem. By default this
# is false, indicating that this counter is reported as a delta.
# Corresponds to the JSON property `cumulative`
# @return [Boolean]
attr_accessor :cumulative
alias_method :cumulative?, :cumulative
# A metric value representing a distribution.
# Corresponds to the JSON property `distribution`
# @return [Google::Apis::DataflowV1b3::DistributionUpdate]
attr_accessor :distribution
# Floating point value for Sum, Max, Min.
# Corresponds to the JSON property `floatingPoint`
# @return [Float]
attr_accessor :floating_point
# A metric value representing a list of floating point numbers.
# Corresponds to the JSON property `floatingPointList`
# @return [Google::Apis::DataflowV1b3::FloatingPointList]
attr_accessor :floating_point_list
# A representation of a floating point mean metric contribution.
# Corresponds to the JSON property `floatingPointMean`
# @return [Google::Apis::DataflowV1b3::FloatingPointMean]
attr_accessor :floating_point_mean
# A representation of an int64, n, that is immune to precision loss when encoded
# in JSON.
# Corresponds to the JSON property `integer`
# @return [Google::Apis::DataflowV1b3::SplitInt64]
attr_accessor :integer
# A metric value representing temporal values of a variable.
# Corresponds to the JSON property `integerGauge`
# @return [Google::Apis::DataflowV1b3::IntegerGauge]
attr_accessor :integer_gauge
# A metric value representing a list of integers.
# Corresponds to the JSON property `integerList`
# @return [Google::Apis::DataflowV1b3::IntegerList]
attr_accessor :integer_list
# A representation of an integer mean metric contribution.
# Corresponds to the JSON property `integerMean`
# @return [Google::Apis::DataflowV1b3::IntegerMean]
attr_accessor :integer_mean
# Value for internally-defined counters used by the Dataflow service.
# Corresponds to the JSON property `internal`
# @return [Object]
attr_accessor :internal
# Basic metadata about a counter.
# Corresponds to the JSON property `nameAndKind`
# @return [Google::Apis::DataflowV1b3::NameAndKind]
attr_accessor :name_and_kind
# The service-generated short identifier for this counter. The short_id -> (name,
# metadata) mapping is constant for the lifetime of a job.
# Corresponds to the JSON property `shortId`
# @return [Fixnum]
attr_accessor :short_id
# A metric value representing a list of strings.
# Corresponds to the JSON property `stringList`
# @return [Google::Apis::DataflowV1b3::StringList]
attr_accessor :string_list
# A single message which encapsulates structured name and metadata for a given
# counter.
# Corresponds to the JSON property `structuredNameAndMetadata`
# @return [Google::Apis::DataflowV1b3::CounterStructuredNameAndMetadata]
attr_accessor :structured_name_and_metadata
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@boolean = args[:boolean] if args.key?(:boolean)
@cumulative = args[:cumulative] if args.key?(:cumulative)
@distribution = args[:distribution] if args.key?(:distribution)
@floating_point = args[:floating_point] if args.key?(:floating_point)
@floating_point_list = args[:floating_point_list] if args.key?(:floating_point_list)
@floating_point_mean = args[:floating_point_mean] if args.key?(:floating_point_mean)
@integer = args[:integer] if args.key?(:integer)
@integer_gauge = args[:integer_gauge] if args.key?(:integer_gauge)
@integer_list = args[:integer_list] if args.key?(:integer_list)
@integer_mean = args[:integer_mean] if args.key?(:integer_mean)
@internal = args[:internal] if args.key?(:internal)
@name_and_kind = args[:name_and_kind] if args.key?(:name_and_kind)
@short_id = args[:short_id] if args.key?(:short_id)
@string_list = args[:string_list] if args.key?(:string_list)
@structured_name_and_metadata = args[:structured_name_and_metadata] if args.key?(:structured_name_and_metadata)
end
end
# A request to create a Cloud Dataflow job from a template.
class CreateJobFromTemplateRequest
include Google::Apis::Core::Hashable
# The environment values to set at runtime.
# Corresponds to the JSON property `environment`
# @return [Google::Apis::DataflowV1b3::RuntimeEnvironment]
attr_accessor :environment
# Required. A Cloud Storage path to the template from which to create the job.
# Must be a valid Cloud Storage URL, beginning with `gs://`.
# Corresponds to the JSON property `gcsPath`
# @return [String]
attr_accessor :gcs_path
# Required. The job name to use for the created job.
# Corresponds to the JSON property `jobName`
# @return [String]
attr_accessor :job_name
# The [regional endpoint] (https://cloud.google.com/dataflow/docs/concepts/
# regional-endpoints) to which to direct the request.
# Corresponds to the JSON property `location`
# @return [String]
attr_accessor :location
# The runtime parameters to pass to the job.
# Corresponds to the JSON property `parameters`
# @return [Hash<String,String>]
attr_accessor :parameters
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@environment = args[:environment] if args.key?(:environment)
@gcs_path = args[:gcs_path] if args.key?(:gcs_path)
@job_name = args[:job_name] if args.key?(:job_name)
@location = args[:location] if args.key?(:location)
@parameters = args[:parameters] if args.key?(:parameters)
end
end
# Creates a new Template with TemplateVersions.
class CreateTemplateVersionRequest
include Google::Apis::Core::Hashable
# ///////////////////////////////////////////////////////////////////////////// /
# /// Template Catalog is used to organize user TemplateVersions. ////
# TemplateVersions that have the same project_id and display_name are ////
# belong to the same Template. //// Templates with the same project_id belong to
# the same Project. //// TemplateVersion may have labels and multiple labels are
# allowed. //// Duplicated labels in the same `TemplateVersion` are not allowed.
# //// TemplateVersion may have tags and multiple tags are allowed. Duplicated //
# // tags in the same `Template` are not allowed!
# Corresponds to the JSON property `templateVersion`
# @return [Google::Apis::DataflowV1b3::TemplateVersion]
attr_accessor :template_version
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@template_version = args[:template_version] if args.key?(:template_version)
end
end
# Identifies the location of a custom souce.
class CustomSourceLocation
include Google::Apis::Core::Hashable
# Whether this source is stateful.
# Corresponds to the JSON property `stateful`
# @return [Boolean]
attr_accessor :stateful
alias_method :stateful?, :stateful
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@stateful = args[:stateful] if args.key?(:stateful)
end
end
# Data disk assignment for a given VM instance.
class DataDiskAssignment
include Google::Apis::Core::Hashable
# Mounted data disks. The order is important a data disk's 0-based index in this
# list defines which persistent directory the disk is mounted to, for example
# the list of ` "myproject-1014-104817-4c2-harness-0-disk-0" `, ` "myproject-
# 1014-104817-4c2-harness-0-disk-1" `.
# Corresponds to the JSON property `dataDisks`
# @return [Array<String>]
attr_accessor :data_disks
# VM instance name the data disks mounted to, for example "myproject-1014-104817-
# 4c2-harness-0".
# Corresponds to the JSON property `vmInstance`
# @return [String]
attr_accessor :vm_instance
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@data_disks = args[:data_disks] if args.key?(:data_disks)
@vm_instance = args[:vm_instance] if args.key?(:vm_instance)
end
end
# Metadata for a Datastore connector used by the job.
class DatastoreIoDetails
include Google::Apis::Core::Hashable
# Namespace used in the connection.
# Corresponds to the JSON property `namespace`
# @return [String]
attr_accessor :namespace
# ProjectId accessed in the connection.
# Corresponds to the JSON property `projectId`
# @return [String]
attr_accessor :project_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@namespace = args[:namespace] if args.key?(:namespace)
@project_id = args[:project_id] if args.key?(:project_id)
end
end
# Response from deleting a snapshot.
class DeleteSnapshotResponse
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# Specification of one of the bundles produced as a result of splitting a Source
# (e.g. when executing a SourceSplitRequest, or when splitting an active task
# using WorkItemStatus.dynamic_source_split), relative to the source being split.
class DerivedSource
include Google::Apis::Core::Hashable
# What source to base the produced source on (if any).
# Corresponds to the JSON property `derivationMode`
# @return [String]
attr_accessor :derivation_mode
# A source that records can be read and decoded from.
# Corresponds to the JSON property `source`
# @return [Google::Apis::DataflowV1b3::Source]
attr_accessor :source
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@derivation_mode = args[:derivation_mode] if args.key?(:derivation_mode)
@source = args[:source] if args.key?(:source)
end
end
# Describes the data disk used by a workflow job.
class Disk
include Google::Apis::Core::Hashable
# Disk storage type, as defined by Google Compute Engine. This must be a disk
# type appropriate to the project and zone in which the workers will run. If
# unknown or unspecified, the service will attempt to choose a reasonable
# default. For example, the standard persistent disk type is a resource name
# typically ending in "pd-standard". If SSD persistent disks are available, the
# resource name typically ends with "pd-ssd". The actual valid values are
# defined the Google Compute Engine API, not by the Cloud Dataflow API; consult