forked from googleapis/google-api-go-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
dataproc-gen.go
3663 lines (3280 loc) · 131 KB
/
dataproc-gen.go
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
// Package dataproc provides access to the Google Cloud Dataproc API.
//
// See https://cloud.google.com/dataproc/
//
// Usage example:
//
// import "google.golang.org/api/dataproc/v1"
// ...
// dataprocService, err := dataproc.New(oauthHttpClient)
package dataproc // import "google.golang.org/api/dataproc/v1"
import (
"bytes"
"encoding/json"
"errors"
"fmt"
context "golang.org/x/net/context"
ctxhttp "golang.org/x/net/context/ctxhttp"
gensupport "google.golang.org/api/gensupport"
googleapi "google.golang.org/api/googleapi"
"io"
"net/http"
"net/url"
"strconv"
"strings"
)
// Always reference these packages, just in case the auto-generated code
// below doesn't.
var _ = bytes.NewBuffer
var _ = strconv.Itoa
var _ = fmt.Sprintf
var _ = json.NewDecoder
var _ = io.Copy
var _ = url.Parse
var _ = gensupport.MarshalJSON
var _ = googleapi.Version
var _ = errors.New
var _ = strings.Replace
var _ = context.Canceled
var _ = ctxhttp.Do
const apiId = "dataproc:v1"
const apiName = "dataproc"
const apiVersion = "v1"
const basePath = "https://dataproc.googleapis.com/"
// OAuth2 scopes used by this API.
const (
// View and manage your data across Google Cloud Platform services
CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
)
func New(client *http.Client) (*Service, error) {
if client == nil {
return nil, errors.New("client is nil")
}
s := &Service{client: client, BasePath: basePath}
s.Projects = NewProjectsService(s)
return s, nil
}
type Service struct {
client *http.Client
BasePath string // API endpoint base URL
UserAgent string // optional additional User-Agent fragment
Projects *ProjectsService
}
func (s *Service) userAgent() string {
if s.UserAgent == "" {
return googleapi.UserAgent
}
return googleapi.UserAgent + " " + s.UserAgent
}
func NewProjectsService(s *Service) *ProjectsService {
rs := &ProjectsService{s: s}
rs.Regions = NewProjectsRegionsService(s)
return rs
}
type ProjectsService struct {
s *Service
Regions *ProjectsRegionsService
}
func NewProjectsRegionsService(s *Service) *ProjectsRegionsService {
rs := &ProjectsRegionsService{s: s}
rs.Clusters = NewProjectsRegionsClustersService(s)
rs.Jobs = NewProjectsRegionsJobsService(s)
rs.Operations = NewProjectsRegionsOperationsService(s)
return rs
}
type ProjectsRegionsService struct {
s *Service
Clusters *ProjectsRegionsClustersService
Jobs *ProjectsRegionsJobsService
Operations *ProjectsRegionsOperationsService
}
func NewProjectsRegionsClustersService(s *Service) *ProjectsRegionsClustersService {
rs := &ProjectsRegionsClustersService{s: s}
return rs
}
type ProjectsRegionsClustersService struct {
s *Service
}
func NewProjectsRegionsJobsService(s *Service) *ProjectsRegionsJobsService {
rs := &ProjectsRegionsJobsService{s: s}
return rs
}
type ProjectsRegionsJobsService struct {
s *Service
}
func NewProjectsRegionsOperationsService(s *Service) *ProjectsRegionsOperationsService {
rs := &ProjectsRegionsOperationsService{s: s}
return rs
}
type ProjectsRegionsOperationsService struct {
s *Service
}
// CancelJobRequest: A request to cancel a job.
type CancelJobRequest struct {
}
// Cluster: Describes the identifying information, config, and status of
// a cluster of Google Compute Engine instances.
type Cluster struct {
// ClusterName: [Required] The cluster name. Cluster names within a
// project must be unique. Names of deleted clusters can be reused.
ClusterName string `json:"clusterName,omitempty"`
// ClusterUuid: [Output-only] A cluster UUID (Unique Universal
// Identifier). Cloud Dataproc generates this value when it creates the
// cluster.
ClusterUuid string `json:"clusterUuid,omitempty"`
// Config: [Required] The cluster config. Note that Cloud Dataproc may
// set default values, and values may change when clusters are updated.
Config *ClusterConfig `json:"config,omitempty"`
// ProjectId: [Required] The Google Cloud Platform project ID that the
// cluster belongs to.
ProjectId string `json:"projectId,omitempty"`
// Status: [Output-only] Cluster status.
Status *ClusterStatus `json:"status,omitempty"`
// StatusHistory: [Output-only] The previous cluster status.
StatusHistory []*ClusterStatus `json:"statusHistory,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "ClusterName") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *Cluster) MarshalJSON() ([]byte, error) {
type noMethod Cluster
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ClusterConfig: The cluster config.
type ClusterConfig struct {
// ConfigBucket: [Optional] A Google Cloud Storage staging bucket used
// for sharing generated SSH keys and config. If you do not specify a
// staging bucket, Cloud Dataproc will determine an appropriate Cloud
// Storage location (US, ASIA, or EU) for your cluster's staging bucket
// according to the Google Compute Engine zone where your cluster is
// deployed, and then it will create and manage this project-level,
// per-location bucket for you.
ConfigBucket string `json:"configBucket,omitempty"`
// GceClusterConfig: [Required] The shared Google Compute Engine config
// settings for all instances in a cluster.
GceClusterConfig *GceClusterConfig `json:"gceClusterConfig,omitempty"`
// InitializationActions: [Optional] Commands to execute on each node
// after config is completed. By default, executables are run on master
// and all worker nodes. You can test a node's role metadata to run an
// executable on a master or worker node, as shown below:
// ROLE=$(/usr/share/google/get_metadata_value attributes/role) if [[
// "${ROLE}" == 'Master' ]]; then ... master specific actions ... else
// ... worker specific actions ... fi
InitializationActions []*NodeInitializationAction `json:"initializationActions,omitempty"`
// MasterConfig: [Optional] The Google Compute Engine config settings
// for the master instance in a cluster.
MasterConfig *InstanceGroupConfig `json:"masterConfig,omitempty"`
// SecondaryWorkerConfig: [Optional] The Google Compute Engine config
// settings for additional worker instances in a cluster.
SecondaryWorkerConfig *InstanceGroupConfig `json:"secondaryWorkerConfig,omitempty"`
// SoftwareConfig: [Optional] The config settings for software inside
// the cluster.
SoftwareConfig *SoftwareConfig `json:"softwareConfig,omitempty"`
// WorkerConfig: [Optional] The Google Compute Engine config settings
// for worker instances in a cluster.
WorkerConfig *InstanceGroupConfig `json:"workerConfig,omitempty"`
// ForceSendFields is a list of field names (e.g. "ConfigBucket") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ClusterConfig) MarshalJSON() ([]byte, error) {
type noMethod ClusterConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ClusterOperationMetadata: Metadata describing the operation.
type ClusterOperationMetadata struct {
// ClusterName: Name of the cluster for the operation.
ClusterName string `json:"clusterName,omitempty"`
// ClusterUuid: Cluster UUId for the operation.
ClusterUuid string `json:"clusterUuid,omitempty"`
// Description: [Output-only] Short description of operation.
Description string `json:"description,omitempty"`
// OperationType: [Output-only] The operation type.
OperationType string `json:"operationType,omitempty"`
// Status: [Output-only] Current operation status.
Status *ClusterOperationStatus `json:"status,omitempty"`
// StatusHistory: [Output-only] The previous operation status.
StatusHistory []*ClusterOperationStatus `json:"statusHistory,omitempty"`
// ForceSendFields is a list of field names (e.g. "ClusterName") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ClusterOperationMetadata) MarshalJSON() ([]byte, error) {
type noMethod ClusterOperationMetadata
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ClusterOperationStatus: The status of the operation.
type ClusterOperationStatus struct {
// Details: A message containing any operation metadata details.
Details string `json:"details,omitempty"`
// InnerState: A message containing the detailed operation state.
InnerState string `json:"innerState,omitempty"`
// State: A message containing the operation state.
//
// Possible values:
// "UNKNOWN"
// "PENDING"
// "RUNNING"
// "DONE"
State string `json:"state,omitempty"`
// StateStartTime: The time this state was entered.
StateStartTime string `json:"stateStartTime,omitempty"`
// ForceSendFields is a list of field names (e.g. "Details") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ClusterOperationStatus) MarshalJSON() ([]byte, error) {
type noMethod ClusterOperationStatus
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ClusterStatus: The status of a cluster and its instances.
type ClusterStatus struct {
// Detail: Optional details of cluster's state.
Detail string `json:"detail,omitempty"`
// State: The cluster's state.
//
// Possible values:
// "UNKNOWN"
// "CREATING"
// "RUNNING"
// "ERROR"
// "DELETING"
// "UPDATING"
State string `json:"state,omitempty"`
// StateStartTime: Time when this state was entered.
StateStartTime string `json:"stateStartTime,omitempty"`
// ForceSendFields is a list of field names (e.g. "Detail") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ClusterStatus) MarshalJSON() ([]byte, error) {
type noMethod ClusterStatus
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// DiagnoseClusterOutputLocation: The location where output from
// diagnostic command can be found.
type DiagnoseClusterOutputLocation struct {
// OutputUri: [Output-only] The Google Cloud Storage URI of the
// diagnostic output. This will be a plain text file with summary of
// collected diagnostics.
OutputUri string `json:"outputUri,omitempty"`
// ForceSendFields is a list of field names (e.g. "OutputUri") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *DiagnoseClusterOutputLocation) MarshalJSON() ([]byte, error) {
type noMethod DiagnoseClusterOutputLocation
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// DiagnoseClusterRequest: A request to collect cluster diagnostic
// information.
type DiagnoseClusterRequest struct {
}
// DiagnoseClusterResults: The location of diagnostic output.
type DiagnoseClusterResults struct {
// OutputUri: [Output-only] The Google Cloud Storage URI of the
// diagnostic output. This is a plain text file with a summary of
// collected diagnostics.
OutputUri string `json:"outputUri,omitempty"`
// ForceSendFields is a list of field names (e.g. "OutputUri") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *DiagnoseClusterResults) MarshalJSON() ([]byte, error) {
type noMethod DiagnoseClusterResults
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// DiskConfig: Specifies the config of disk options for a group of VM
// instances.
type DiskConfig struct {
// BootDiskSizeGb: [Optional] Size in GB of the boot disk (default is
// 500GB).
BootDiskSizeGb int64 `json:"bootDiskSizeGb,omitempty"`
// NumLocalSsds: [Optional] Number of attached SSDs, from 0 to 4
// (default is 0). If SSDs are not attached, the boot disk is used to
// store runtime logs and HDFS data. If one or more SSDs are attached,
// this runtime bulk data is spread across them, and the boot disk
// contains only basic config and installed binaries.
NumLocalSsds int64 `json:"numLocalSsds,omitempty"`
// ForceSendFields is a list of field names (e.g. "BootDiskSizeGb") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *DiskConfig) MarshalJSON() ([]byte, error) {
type noMethod DiskConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// Empty: A generic empty message that you can re-use to avoid defining
// duplicated empty messages in your APIs. A typical example is to use
// it as the request or the response type of an API method. For
// instance: service Foo { rpc Bar(google.protobuf.Empty) returns
// (google.protobuf.Empty); } The JSON representation for `Empty` is
// empty JSON object `{}`.
type Empty struct {
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
}
// GceClusterConfig: Common config settings for resources of Google
// Compute Engine cluster instances, applicable to all instances in the
// cluster.
type GceClusterConfig struct {
// Metadata: The Google Compute Engine metadata entries to add to all
// instances.
Metadata map[string]string `json:"metadata,omitempty"`
// NetworkUri: The Google Compute Engine network to be used for machine
// communications. Cannot be specified with subnetwork_uri. If neither
// network_uri nor subnetwork_uri is specified, the "default" network of
// the project is used, if it exists. Cannot be a "Custom Subnet
// Network" (see https://cloud.google.com/compute/docs/subnetworks for
// more information). Example:
// `https://www.googleapis.com/compute/v1/projects/[project_id]/regions/g
// lobal/default`.
NetworkUri string `json:"networkUri,omitempty"`
// ServiceAccountScopes: The URIs of service account scopes to be
// included in Google Compute Engine instances. The following base set
// of scopes is always included: *
// https://www.googleapis.com/auth/cloud.useraccounts.readonly *
// https://www.googleapis.com/auth/devstorage.read_write *
// https://www.googleapis.com/auth/logging.write If no scopes are
// specfied, the following defaults are also provided: *
// https://www.googleapis.com/auth/bigquery *
// https://www.googleapis.com/auth/bigtable.admin.table *
// https://www.googleapis.com/auth/bigtable.data *
// https://www.googleapis.com/auth/devstorage.full_control
ServiceAccountScopes []string `json:"serviceAccountScopes,omitempty"`
// SubnetworkUri: The Google Compute Engine subnetwork to be used for
// machine communications. Cannot be specified with network_uri.
// Example:
// `https://www.googleapis.com/compute/v1/projects/[project_id]/regions/u
// s-east1/sub0`.
SubnetworkUri string `json:"subnetworkUri,omitempty"`
// Tags: The Google Compute Engine tags to add to all instances.
Tags []string `json:"tags,omitempty"`
// ZoneUri: [Required] The zone where the Google Compute Engine cluster
// will be located. Example:
// `https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zo
// ne]`.
ZoneUri string `json:"zoneUri,omitempty"`
// ForceSendFields is a list of field names (e.g. "Metadata") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *GceClusterConfig) MarshalJSON() ([]byte, error) {
type noMethod GceClusterConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// HadoopJob: A Cloud Dataproc job for running Hadoop MapReduce jobs on
// YARN.
type HadoopJob struct {
// ArchiveUris: [Optional] HCFS URIs of archives to be extracted in the
// working directory of Hadoop drivers and tasks. Supported file types:
// .jar, .tar, .tar.gz, .tgz, or .zip.
ArchiveUris []string `json:"archiveUris,omitempty"`
// Args: [Optional] The arguments to pass to the driver. Do not include
// arguments, such as `-libjars` or `-Dfoo=bar`, that can be set as job
// properties, since a collision may occur that causes an incorrect job
// submission.
Args []string `json:"args,omitempty"`
// FileUris: [Optional] HCFS (Hadoop Compatible Filesystem) URIs of
// files to be copied to the working directory of Hadoop drivers and
// distributed tasks. Useful for naively parallel tasks.
FileUris []string `json:"fileUris,omitempty"`
// JarFileUris: [Optional] Jar file URIs to add to the CLASSPATHs of the
// Hadoop driver and tasks.
JarFileUris []string `json:"jarFileUris,omitempty"`
// LoggingConfig: [Optional] The runtime log config for job execution.
LoggingConfig *LoggingConfig `json:"loggingConfig,omitempty"`
// MainClass: The name of the driver's main class. The jar file
// containing the class must be in the default CLASSPATH or specified in
// `jar_file_uris`.
MainClass string `json:"mainClass,omitempty"`
// MainJarFileUri: The HCFS URI of the jar file containing the main
// class. Examples:
// 'gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar'
// 'hdfs:/tmp/test-samples/custom-wordcount.jar'
// 'file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar'
MainJarFileUri string `json:"mainJarFileUri,omitempty"`
// Properties: [Optional] A mapping of property names to values, used to
// configure Hadoop. Properties that conflict with values set by the
// Cloud Dataproc API may be overwritten. Can include properties set in
// /etc/hadoop/conf/*-site and classes in user code.
Properties map[string]string `json:"properties,omitempty"`
// ForceSendFields is a list of field names (e.g. "ArchiveUris") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *HadoopJob) MarshalJSON() ([]byte, error) {
type noMethod HadoopJob
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// HiveJob: A Cloud Dataproc job for running Hive queries on YARN.
type HiveJob struct {
// ContinueOnFailure: [Optional] Whether to continue executing queries
// if a query fails. The default value is `false`. Setting to `true` can
// be useful when executing independent parallel queries.
ContinueOnFailure bool `json:"continueOnFailure,omitempty"`
// JarFileUris: [Optional] HCFS URIs of jar files to add to the
// CLASSPATH of the Hive server and Hadoop MapReduce (MR) tasks. Can
// contain Hive SerDes and UDFs.
JarFileUris []string `json:"jarFileUris,omitempty"`
// Properties: [Optional] A mapping of property names and values, used
// to configure Hive. Properties that conflict with values set by the
// Cloud Dataproc API may be overwritten. Can include properties set in
// /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and
// classes in user code.
Properties map[string]string `json:"properties,omitempty"`
// QueryFileUri: The HCFS URI of the script that contains Hive queries.
QueryFileUri string `json:"queryFileUri,omitempty"`
// QueryList: A list of queries.
QueryList *QueryList `json:"queryList,omitempty"`
// ScriptVariables: [Optional] Mapping of query variable names to values
// (equivalent to the Hive command: `SET name="value";`).
ScriptVariables map[string]string `json:"scriptVariables,omitempty"`
// ForceSendFields is a list of field names (e.g. "ContinueOnFailure")
// to unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *HiveJob) MarshalJSON() ([]byte, error) {
type noMethod HiveJob
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// InstanceGroupConfig: The config settings for Google Compute Engine
// resources in an instance group, such as a master or worker group.
type InstanceGroupConfig struct {
// DiskConfig: Disk option config settings.
DiskConfig *DiskConfig `json:"diskConfig,omitempty"`
// ImageUri: [Output-only] The Google Compute Engine image resource used
// for cluster instances. Inferred from `SoftwareConfig.image_version`.
ImageUri string `json:"imageUri,omitempty"`
// InstanceNames: The list of instance names. Cloud Dataproc derives the
// names from `cluster_name`, `num_instances`, and the instance group if
// not set by user (recommended practice is to let Cloud Dataproc derive
// the name).
InstanceNames []string `json:"instanceNames,omitempty"`
// IsPreemptible: Specifies that this instance group contains
// Preemptible Instances.
IsPreemptible bool `json:"isPreemptible,omitempty"`
// MachineTypeUri: The Google Compute Engine machine type used for
// cluster instances. Example:
// `https://www.googleapis.com/compute/v1/projects/[project_id]/zones/us-
// east1-a/machineTypes/n1-standard-2`.
MachineTypeUri string `json:"machineTypeUri,omitempty"`
// ManagedGroupConfig: [Output-only] The config for Google Compute
// Engine Instance Group Manager that manages this group. This is only
// used for preemptible instance groups.
ManagedGroupConfig *ManagedGroupConfig `json:"managedGroupConfig,omitempty"`
// NumInstances: The number of VM instances in the instance group. For
// master instance groups, must be set to 1.
NumInstances int64 `json:"numInstances,omitempty"`
// ForceSendFields is a list of field names (e.g. "DiskConfig") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *InstanceGroupConfig) MarshalJSON() ([]byte, error) {
type noMethod InstanceGroupConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// Job: A Cloud Dataproc job resource.
type Job struct {
// DriverControlFilesUri: [Output-only] If present, the location of
// miscellaneous control files which may be used as part of job setup
// and handling. If not present, control files may be placed in the same
// location as `driver_output_uri`.
DriverControlFilesUri string `json:"driverControlFilesUri,omitempty"`
// DriverOutputResourceUri: [Output-only] A URI pointing to the location
// of the stdout of the job's driver program.
DriverOutputResourceUri string `json:"driverOutputResourceUri,omitempty"`
// HadoopJob: Job is a Hadoop job.
HadoopJob *HadoopJob `json:"hadoopJob,omitempty"`
// HiveJob: Job is a Hive job.
HiveJob *HiveJob `json:"hiveJob,omitempty"`
// PigJob: Job is a Pig job.
PigJob *PigJob `json:"pigJob,omitempty"`
// Placement: [Required] Job information, including how, when, and where
// to run the job.
Placement *JobPlacement `json:"placement,omitempty"`
// PysparkJob: Job is a Pyspark job.
PysparkJob *PySparkJob `json:"pysparkJob,omitempty"`
// Reference: [Optional] The fully qualified reference to the job, which
// can be used to obtain the equivalent REST path of the job resource.
// If this property is not specified when a job is created, the server
// generates a job_id.
Reference *JobReference `json:"reference,omitempty"`
// SparkJob: Job is a Spark job.
SparkJob *SparkJob `json:"sparkJob,omitempty"`
// SparkSqlJob: Job is a SparkSql job.
SparkSqlJob *SparkSqlJob `json:"sparkSqlJob,omitempty"`
// Status: [Output-only] The job status. Additional application-specific
// status information may be contained in the type_job and
// yarn_applications fields.
Status *JobStatus `json:"status,omitempty"`
// StatusHistory: [Output-only] The previous job status.
StatusHistory []*JobStatus `json:"statusHistory,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g.
// "DriverControlFilesUri") to unconditionally include in API requests.
// By default, fields with empty values are omitted from API requests.
// However, any non-pointer, non-interface field appearing in
// ForceSendFields will be sent to the server regardless of whether the
// field is empty or not. This may be used to include empty fields in
// Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *Job) MarshalJSON() ([]byte, error) {
type noMethod Job
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// JobPlacement: Cloud Dataproc job config.
type JobPlacement struct {
// ClusterName: [Required] The name of the cluster where the job will be
// submitted.
ClusterName string `json:"clusterName,omitempty"`
// ClusterUuid: [Output-only] A cluster UUID generated by the Cloud
// Dataproc service when the job is submitted.
ClusterUuid string `json:"clusterUuid,omitempty"`
// ForceSendFields is a list of field names (e.g. "ClusterName") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *JobPlacement) MarshalJSON() ([]byte, error) {
type noMethod JobPlacement
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// JobReference: Encapsulates the full scoping used to reference a job.
type JobReference struct {
// JobId: [Required] The job ID, which must be unique within the
// project. The job ID is generated by the server upon job submission or
// provided by the user as a means to perform retries without creating
// duplicate jobs. The ID must contain only letters (a-z, A-Z), numbers
// (0-9), underscores (_), or hyphens (-). The maximum length is 512
// characters.
JobId string `json:"jobId,omitempty"`
// ProjectId: [Required] The ID of the Google Cloud Platform project
// that the job belongs to.
ProjectId string `json:"projectId,omitempty"`
// ForceSendFields is a list of field names (e.g. "JobId") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *JobReference) MarshalJSON() ([]byte, error) {
type noMethod JobReference
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// JobStatus: Cloud Dataproc job status.
type JobStatus struct {
// Details: [Optional] Job state details, such as an error description
// if the state is ERROR.
Details string `json:"details,omitempty"`
// State: [Required] A state message specifying the overall job state.
//
// Possible values:
// "STATE_UNSPECIFIED"
// "PENDING"
// "SETUP_DONE"
// "RUNNING"
// "CANCEL_PENDING"
// "CANCEL_STARTED"
// "CANCELLED"
// "DONE"
// "ERROR"
State string `json:"state,omitempty"`
// StateStartTime: [Output-only] The time when this state was entered.
StateStartTime string `json:"stateStartTime,omitempty"`
// ForceSendFields is a list of field names (e.g. "Details") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *JobStatus) MarshalJSON() ([]byte, error) {
type noMethod JobStatus
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ListClustersResponse: The list of all clusters in a project.
type ListClustersResponse struct {
// Clusters: [Output-only] The clusters in the project.
Clusters []*Cluster `json:"clusters,omitempty"`
// NextPageToken: [Optional] This token is included in the response if
// there are more results to fetch. To fetch additional results, provide
// this value as the `page_token` in a subsequent ListClustersRequest.
NextPageToken string `json:"nextPageToken,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Clusters") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ListClustersResponse) MarshalJSON() ([]byte, error) {
type noMethod ListClustersResponse
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ListJobsResponse: A list of jobs in a project.
type ListJobsResponse struct {
// Jobs: [Output-only] Jobs list.
Jobs []*Job `json:"jobs,omitempty"`
// NextPageToken: [Optional] This token is included in the response if
// there are more results to fetch. To fetch additional results, provide
// this value as the `page_token` in a subsequent ListJobsRequest.
NextPageToken string `json:"nextPageToken,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Jobs") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ListJobsResponse) MarshalJSON() ([]byte, error) {
type noMethod ListJobsResponse
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ListOperationsResponse: The response message for
// Operations.ListOperations.
type ListOperationsResponse struct {
// NextPageToken: The standard List next-page token.
NextPageToken string `json:"nextPageToken,omitempty"`
// Operations: A list of operations that matches the specified filter in
// the request.
Operations []*Operation `json:"operations,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "NextPageToken") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
type noMethod ListOperationsResponse
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// LoggingConfig: The runtime logging config of the job.
type LoggingConfig struct {
// DriverLogLevels: The per-package log levels for the driver. This may
// include "root" package name to configure rootLogger. Examples:
// 'com.google = FATAL', 'root = INFO', 'org.apache = DEBUG'
DriverLogLevels map[string]string `json:"driverLogLevels,omitempty"`
// ForceSendFields is a list of field names (e.g. "DriverLogLevels") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *LoggingConfig) MarshalJSON() ([]byte, error) {
type noMethod LoggingConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// ManagedGroupConfig: Specifies the resources used to actively manage
// an instance group.
type ManagedGroupConfig struct {
// InstanceGroupManagerName: [Output-only] The name of the Instance
// Group Manager for this group.
InstanceGroupManagerName string `json:"instanceGroupManagerName,omitempty"`
// InstanceTemplateName: [Output-only] The name of the Instance Template
// used for the Managed Instance Group.
InstanceTemplateName string `json:"instanceTemplateName,omitempty"`
// ForceSendFields is a list of field names (e.g.
// "InstanceGroupManagerName") to unconditionally include in API
// requests. By default, fields with empty values are omitted from API
// requests. However, any non-pointer, non-interface field appearing in
// ForceSendFields will be sent to the server regardless of whether the
// field is empty or not. This may be used to include empty fields in
// Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *ManagedGroupConfig) MarshalJSON() ([]byte, error) {
type noMethod ManagedGroupConfig
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// NodeInitializationAction: Specifies an executable to run on a fully
// configured node and a timeout period for executable completion.
type NodeInitializationAction struct {
// ExecutableFile: [Required] Google Cloud Storage URI of executable
// file.
ExecutableFile string `json:"executableFile,omitempty"`
// ExecutionTimeout: [Optional] Amount of time executable has to
// complete. Default is 10 minutes. Cluster creation fails with an
// explanatory error message (the name of the executable that caused the
// error and the exceeded timeout period) if the executable is not
// completed at end of the timeout period.
ExecutionTimeout string `json:"executionTimeout,omitempty"`
// ForceSendFields is a list of field names (e.g. "ExecutableFile") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
}
func (s *NodeInitializationAction) MarshalJSON() ([]byte, error) {
type noMethod NodeInitializationAction
raw := noMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields)
}
// Operation: This resource represents a long-running operation that is
// the result of a network API call.
type Operation struct {
// Done: If the value is `false`, it means the operation is still in
// progress. If true, the operation is completed, and either `error` or
// `response` is available.
Done bool `json:"done,omitempty"`
// Error: The error result of the operation in case of failure.
Error *Status `json:"error,omitempty"`
// Metadata: Service-specific metadata associated with the operation. It
// typically contains progress information and common metadata such as
// create time. Some services might not provide such metadata. Any
// method that returns a long-running operation should document the
// metadata type, if any.
Metadata OperationMetadata `json:"metadata,omitempty"`
// Name: The server-assigned name, which is only unique within the same
// service that originally returns it. If you use the default HTTP
// mapping, the `name` should have the format of
// `operations/some/unique/name`.
Name string `json:"name,omitempty"`
// Response: The normal response of the operation in case of success. If
// the original method returns no data on success, such as `Delete`, the
// response is `google.protobuf.Empty`. If the original method is