-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
vmmigration-gen.go
11728 lines (10691 loc) · 444 KB
/
vmmigration-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
// Copyright 2022 Google LLC.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// Code generated file. DO NOT EDIT.
// Package vmmigration provides access to the VM Migration API.
//
// For product documentation, see: https://cloud.google.com/migrate/compute-engine
//
// Creating a client
//
// Usage example:
//
// import "google.golang.org/api/vmmigration/v1"
// ...
// ctx := context.Background()
// vmmigrationService, err := vmmigration.NewService(ctx)
//
// In this example, Google Application Default Credentials are used for authentication.
//
// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
//
// Other authentication options
//
// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
//
// vmmigrationService, err := vmmigration.NewService(ctx, option.WithAPIKey("AIza..."))
//
// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
//
// config := &oauth2.Config{...}
// // ...
// token, err := config.Exchange(ctx, ...)
// vmmigrationService, err := vmmigration.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
//
// See https://godoc.org/google.golang.org/api/option/ for details on options.
package vmmigration // import "google.golang.org/api/vmmigration/v1"
import (
"bytes"
"context"
"encoding/json"
"errors"
"fmt"
"io"
"net/http"
"net/url"
"strconv"
"strings"
googleapi "google.golang.org/api/googleapi"
internal "google.golang.org/api/internal"
gensupport "google.golang.org/api/internal/gensupport"
option "google.golang.org/api/option"
internaloption "google.golang.org/api/option/internaloption"
htransport "google.golang.org/api/transport/http"
)
// 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 _ = internaloption.WithDefaultEndpoint
const apiId = "vmmigration:v1"
const apiName = "vmmigration"
const apiVersion = "v1"
const basePath = "https://vmmigration.googleapis.com/"
const mtlsBasePath = "https://vmmigration.mtls.googleapis.com/"
// OAuth2 scopes used by this API.
const (
// See, edit, configure, and delete your Google Cloud data and see the
// email address for your Google Account.
CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
)
// NewService creates a new Service.
func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
scopesOption := internaloption.WithDefaultScopes(
"https://www.googleapis.com/auth/cloud-platform",
)
// NOTE: prepend, so we don't override user-specified scopes.
opts = append([]option.ClientOption{scopesOption}, opts...)
opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
client, endpoint, err := htransport.NewClient(ctx, opts...)
if err != nil {
return nil, err
}
s, err := New(client)
if err != nil {
return nil, err
}
if endpoint != "" {
s.BasePath = endpoint
}
return s, nil
}
// New creates a new Service. It uses the provided http.Client for requests.
//
// Deprecated: please use NewService instead.
// To provide a custom HTTP client, use option.WithHTTPClient.
// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
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.Locations = NewProjectsLocationsService(s)
return rs
}
type ProjectsService struct {
s *Service
Locations *ProjectsLocationsService
}
func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
rs := &ProjectsLocationsService{s: s}
rs.Groups = NewProjectsLocationsGroupsService(s)
rs.Operations = NewProjectsLocationsOperationsService(s)
rs.Sources = NewProjectsLocationsSourcesService(s)
rs.TargetProjects = NewProjectsLocationsTargetProjectsService(s)
return rs
}
type ProjectsLocationsService struct {
s *Service
Groups *ProjectsLocationsGroupsService
Operations *ProjectsLocationsOperationsService
Sources *ProjectsLocationsSourcesService
TargetProjects *ProjectsLocationsTargetProjectsService
}
func NewProjectsLocationsGroupsService(s *Service) *ProjectsLocationsGroupsService {
rs := &ProjectsLocationsGroupsService{s: s}
return rs
}
type ProjectsLocationsGroupsService struct {
s *Service
}
func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
rs := &ProjectsLocationsOperationsService{s: s}
return rs
}
type ProjectsLocationsOperationsService struct {
s *Service
}
func NewProjectsLocationsSourcesService(s *Service) *ProjectsLocationsSourcesService {
rs := &ProjectsLocationsSourcesService{s: s}
rs.DatacenterConnectors = NewProjectsLocationsSourcesDatacenterConnectorsService(s)
rs.MigratingVms = NewProjectsLocationsSourcesMigratingVmsService(s)
rs.UtilizationReports = NewProjectsLocationsSourcesUtilizationReportsService(s)
return rs
}
type ProjectsLocationsSourcesService struct {
s *Service
DatacenterConnectors *ProjectsLocationsSourcesDatacenterConnectorsService
MigratingVms *ProjectsLocationsSourcesMigratingVmsService
UtilizationReports *ProjectsLocationsSourcesUtilizationReportsService
}
func NewProjectsLocationsSourcesDatacenterConnectorsService(s *Service) *ProjectsLocationsSourcesDatacenterConnectorsService {
rs := &ProjectsLocationsSourcesDatacenterConnectorsService{s: s}
return rs
}
type ProjectsLocationsSourcesDatacenterConnectorsService struct {
s *Service
}
func NewProjectsLocationsSourcesMigratingVmsService(s *Service) *ProjectsLocationsSourcesMigratingVmsService {
rs := &ProjectsLocationsSourcesMigratingVmsService{s: s}
rs.CloneJobs = NewProjectsLocationsSourcesMigratingVmsCloneJobsService(s)
rs.CutoverJobs = NewProjectsLocationsSourcesMigratingVmsCutoverJobsService(s)
rs.ReplicationCycles = NewProjectsLocationsSourcesMigratingVmsReplicationCyclesService(s)
return rs
}
type ProjectsLocationsSourcesMigratingVmsService struct {
s *Service
CloneJobs *ProjectsLocationsSourcesMigratingVmsCloneJobsService
CutoverJobs *ProjectsLocationsSourcesMigratingVmsCutoverJobsService
ReplicationCycles *ProjectsLocationsSourcesMigratingVmsReplicationCyclesService
}
func NewProjectsLocationsSourcesMigratingVmsCloneJobsService(s *Service) *ProjectsLocationsSourcesMigratingVmsCloneJobsService {
rs := &ProjectsLocationsSourcesMigratingVmsCloneJobsService{s: s}
return rs
}
type ProjectsLocationsSourcesMigratingVmsCloneJobsService struct {
s *Service
}
func NewProjectsLocationsSourcesMigratingVmsCutoverJobsService(s *Service) *ProjectsLocationsSourcesMigratingVmsCutoverJobsService {
rs := &ProjectsLocationsSourcesMigratingVmsCutoverJobsService{s: s}
return rs
}
type ProjectsLocationsSourcesMigratingVmsCutoverJobsService struct {
s *Service
}
func NewProjectsLocationsSourcesMigratingVmsReplicationCyclesService(s *Service) *ProjectsLocationsSourcesMigratingVmsReplicationCyclesService {
rs := &ProjectsLocationsSourcesMigratingVmsReplicationCyclesService{s: s}
return rs
}
type ProjectsLocationsSourcesMigratingVmsReplicationCyclesService struct {
s *Service
}
func NewProjectsLocationsSourcesUtilizationReportsService(s *Service) *ProjectsLocationsSourcesUtilizationReportsService {
rs := &ProjectsLocationsSourcesUtilizationReportsService{s: s}
return rs
}
type ProjectsLocationsSourcesUtilizationReportsService struct {
s *Service
}
func NewProjectsLocationsTargetProjectsService(s *Service) *ProjectsLocationsTargetProjectsService {
rs := &ProjectsLocationsTargetProjectsService{s: s}
return rs
}
type ProjectsLocationsTargetProjectsService struct {
s *Service
}
// AddGroupMigrationRequest: Request message for 'AddGroupMigration'
// request.
type AddGroupMigrationRequest struct {
// MigratingVm: The full path name of the MigratingVm to add.
MigratingVm string `json:"migratingVm,omitempty"`
// ForceSendFields is a list of field names (e.g. "MigratingVm") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "MigratingVm") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AddGroupMigrationRequest) MarshalJSON() ([]byte, error) {
type NoMethod AddGroupMigrationRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// ApplianceVersion: Describes an appliance version.
type ApplianceVersion struct {
// Critical: Determine whether it's critical to upgrade the appliance to
// this version.
Critical bool `json:"critical,omitempty"`
// ReleaseNotesUri: Link to a page that contains the version release
// notes.
ReleaseNotesUri string `json:"releaseNotesUri,omitempty"`
// Uri: A link for downloading the version.
Uri string `json:"uri,omitempty"`
// Version: The appliance version.
Version string `json:"version,omitempty"`
// ForceSendFields is a list of field names (e.g. "Critical") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "Critical") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *ApplianceVersion) MarshalJSON() ([]byte, error) {
type NoMethod ApplianceVersion
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AppliedLicense: AppliedLicense holds the license data returned by
// adaptation module report.
type AppliedLicense struct {
// OsLicense: The OS license returned from the adaptation module's
// report.
OsLicense string `json:"osLicense,omitempty"`
// Type: The license type that was used in OS adaptation.
//
// Possible values:
// "TYPE_UNSPECIFIED" - Unspecified license for the OS.
// "NONE" - No license available for the OS.
// "PAYG" - The license type is Pay As You Go license type.
// "BYOL" - The license type is is Bring Your Own License type.
Type string `json:"type,omitempty"`
// ForceSendFields is a list of field names (e.g. "OsLicense") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "OsLicense") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AppliedLicense) MarshalJSON() ([]byte, error) {
type NoMethod AppliedLicense
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AvailableUpdates: Holds informatiom about the available versions for
// upgrade.
type AvailableUpdates struct {
// InPlaceUpdate: The latest version for in place update. The current
// appliance can be updated to this version using the API or m4c CLI.
InPlaceUpdate *ApplianceVersion `json:"inPlaceUpdate,omitempty"`
// NewDeployableAppliance: The newest deployable version of the
// appliance. The current appliance can't be updated into this version,
// and the owner must manually deploy this OVA to a new appliance.
NewDeployableAppliance *ApplianceVersion `json:"newDeployableAppliance,omitempty"`
// ForceSendFields is a list of field names (e.g. "InPlaceUpdate") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "InPlaceUpdate") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AvailableUpdates) MarshalJSON() ([]byte, error) {
type NoMethod AvailableUpdates
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// AwsSourceVmDetails: Represent the source AWS VM details.
type AwsSourceVmDetails struct {
// Firmware: The firmware type of the source VM.
//
// Possible values:
// "FIRMWARE_UNSPECIFIED" - The firmware is unknown.
// "EFI" - The firmware is EFI.
// "BIOS" - The firmware is BIOS.
Firmware string `json:"firmware,omitempty"`
// ForceSendFields is a list of field names (e.g. "Firmware") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "Firmware") to include in
// API requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AwsSourceVmDetails) MarshalJSON() ([]byte, error) {
type NoMethod AwsSourceVmDetails
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CancelCloneJobRequest: Request message for 'CancelCloneJob' request.
type CancelCloneJobRequest struct {
}
// CancelCutoverJobRequest: Request message for 'CancelCutoverJob'
// request.
type CancelCutoverJobRequest struct {
}
// CancelOperationRequest: The request message for
// Operations.CancelOperation.
type CancelOperationRequest struct {
}
// CloneJob: CloneJob describes the process of creating a clone of a
// MigratingVM to the requested target based on the latest successful
// uploaded snapshots. While the migration cycles of a MigratingVm take
// place, it is possible to verify the uploaded VM can be started in the
// cloud, by creating a clone. The clone can be created without any
// downtime, and it is created using the latest snapshots which are
// already in the cloud. The cloneJob is only responsible for its work,
// not its products, which means once it is finished, it will never
// touch the instance it created. It will only delete it in case of the
// CloneJob being cancelled or upon failure to clone.
type CloneJob struct {
// ComputeEngineTargetDetails: Output only. Details of the target VM in
// Compute Engine.
ComputeEngineTargetDetails *ComputeEngineTargetDetails `json:"computeEngineTargetDetails,omitempty"`
// CreateTime: Output only. The time the clone job was created (as an
// API call, not when it was actually created in the target).
CreateTime string `json:"createTime,omitempty"`
// EndTime: Output only. The time the clone job was ended.
EndTime string `json:"endTime,omitempty"`
// Error: Output only. Provides details for the errors that led to the
// Clone Job's state.
Error *Status `json:"error,omitempty"`
// Name: Output only. The name of the clone.
Name string `json:"name,omitempty"`
// State: Output only. State of the clone job.
//
// Possible values:
// "STATE_UNSPECIFIED" - The state is unknown. This is used for API
// compatibility only and is not used by the system.
// "PENDING" - The clone job has not yet started.
// "ACTIVE" - The clone job is active and running.
// "FAILED" - The clone job finished with errors.
// "SUCCEEDED" - The clone job finished successfully.
// "CANCELLED" - The clone job was cancelled.
// "CANCELLING" - The clone job is being cancelled.
// "ADAPTING_OS" - OS adaptation is running as part of the clone job
// to generate license.
State string `json:"state,omitempty"`
// StateTime: Output only. The time the state was last updated.
StateTime string `json:"stateTime,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g.
// "ComputeEngineTargetDetails") to unconditionally include in API
// requests. By default, fields with empty or default 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:"-"`
// NullFields is a list of field names (e.g.
// "ComputeEngineTargetDetails") to include in API requests with the
// JSON null value. By default, fields with empty values are omitted
// from API requests. However, any field with an empty value appearing
// in NullFields will be sent to the server as null. It is an error if a
// field in this list has a non-empty value. This may be used to include
// null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CloneJob) MarshalJSON() ([]byte, error) {
type NoMethod CloneJob
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// ComputeEngineTargetDefaults: ComputeEngineTargetDefaults is a
// collection of details for creating a VM in a target Compute Engine
// project.
type ComputeEngineTargetDefaults struct {
// AdditionalLicenses: Additional licenses to assign to the VM.
AdditionalLicenses []string `json:"additionalLicenses,omitempty"`
// AppliedLicense: Output only. The OS license returned from the
// adaptation module report.
AppliedLicense *AppliedLicense `json:"appliedLicense,omitempty"`
// BootOption: Output only. The VM Boot Option, as set in the source vm.
//
// Possible values:
// "COMPUTE_ENGINE_BOOT_OPTION_UNSPECIFIED" - The boot option is
// unknown.
// "COMPUTE_ENGINE_BOOT_OPTION_EFI" - The boot option is EFI.
// "COMPUTE_ENGINE_BOOT_OPTION_BIOS" - The boot option is BIOS.
BootOption string `json:"bootOption,omitempty"`
// ComputeScheduling: Compute instance scheduling information (if empty
// default is used).
ComputeScheduling *ComputeScheduling `json:"computeScheduling,omitempty"`
// DiskType: The disk type to use in the VM.
//
// Possible values:
// "COMPUTE_ENGINE_DISK_TYPE_UNSPECIFIED" - An unspecified disk type.
// Will be used as STANDARD.
// "COMPUTE_ENGINE_DISK_TYPE_STANDARD" - A Standard disk type.
// "COMPUTE_ENGINE_DISK_TYPE_SSD" - SSD hard disk type.
// "COMPUTE_ENGINE_DISK_TYPE_BALANCED" - An alternative to SSD
// persistent disks that balance performance and cost.
DiskType string `json:"diskType,omitempty"`
// Hostname: The hostname to assign to the VM.
Hostname string `json:"hostname,omitempty"`
// Labels: A map of labels to associate with the VM.
Labels map[string]string `json:"labels,omitempty"`
// LicenseType: The license type to use in OS adaptation.
//
// Possible values:
// "COMPUTE_ENGINE_LICENSE_TYPE_DEFAULT" - The license type is the
// default for the OS.
// "COMPUTE_ENGINE_LICENSE_TYPE_PAYG" - The license type is Pay As You
// Go license type.
// "COMPUTE_ENGINE_LICENSE_TYPE_BYOL" - The license type is Bring Your
// Own License type.
LicenseType string `json:"licenseType,omitempty"`
// MachineType: The machine type to create the VM with.
MachineType string `json:"machineType,omitempty"`
// MachineTypeSeries: The machine type series to create the VM with.
MachineTypeSeries string `json:"machineTypeSeries,omitempty"`
// Metadata: The metadata key/value pairs to assign to the VM.
Metadata map[string]string `json:"metadata,omitempty"`
// NetworkInterfaces: List of NICs connected to this VM.
NetworkInterfaces []*NetworkInterface `json:"networkInterfaces,omitempty"`
// NetworkTags: A map of network tags to associate with the VM.
NetworkTags []string `json:"networkTags,omitempty"`
// SecureBoot: Defines whether the instance has Secure Boot enabled.
// This can be set to true only if the vm boot option is EFI.
SecureBoot bool `json:"secureBoot,omitempty"`
// ServiceAccount: The service account to associate the VM with.
ServiceAccount string `json:"serviceAccount,omitempty"`
// TargetProject: The full path of the resource of type TargetProject
// which represents the Compute Engine project in which to create this
// VM.
TargetProject string `json:"targetProject,omitempty"`
// VmName: The name of the VM to create.
VmName string `json:"vmName,omitempty"`
// Zone: The zone in which to create the VM.
Zone string `json:"zone,omitempty"`
// ForceSendFields is a list of field names (e.g. "AdditionalLicenses")
// to unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "AdditionalLicenses") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *ComputeEngineTargetDefaults) MarshalJSON() ([]byte, error) {
type NoMethod ComputeEngineTargetDefaults
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// ComputeEngineTargetDetails: ComputeEngineTargetDetails is a
// collection of details for creating a VM in a target Compute Engine
// project.
type ComputeEngineTargetDetails struct {
// AdditionalLicenses: Additional licenses to assign to the VM.
AdditionalLicenses []string `json:"additionalLicenses,omitempty"`
// AppliedLicense: The OS license returned from the adaptation module
// report.
AppliedLicense *AppliedLicense `json:"appliedLicense,omitempty"`
// BootOption: The VM Boot Option, as set in the source vm.
//
// Possible values:
// "COMPUTE_ENGINE_BOOT_OPTION_UNSPECIFIED" - The boot option is
// unknown.
// "COMPUTE_ENGINE_BOOT_OPTION_EFI" - The boot option is EFI.
// "COMPUTE_ENGINE_BOOT_OPTION_BIOS" - The boot option is BIOS.
BootOption string `json:"bootOption,omitempty"`
// ComputeScheduling: Compute instance scheduling information (if empty
// default is used).
ComputeScheduling *ComputeScheduling `json:"computeScheduling,omitempty"`
// DiskType: The disk type to use in the VM.
//
// Possible values:
// "COMPUTE_ENGINE_DISK_TYPE_UNSPECIFIED" - An unspecified disk type.
// Will be used as STANDARD.
// "COMPUTE_ENGINE_DISK_TYPE_STANDARD" - A Standard disk type.
// "COMPUTE_ENGINE_DISK_TYPE_SSD" - SSD hard disk type.
// "COMPUTE_ENGINE_DISK_TYPE_BALANCED" - An alternative to SSD
// persistent disks that balance performance and cost.
DiskType string `json:"diskType,omitempty"`
// Hostname: The hostname to assign to the VM.
Hostname string `json:"hostname,omitempty"`
// Labels: A map of labels to associate with the VM.
Labels map[string]string `json:"labels,omitempty"`
// LicenseType: The license type to use in OS adaptation.
//
// Possible values:
// "COMPUTE_ENGINE_LICENSE_TYPE_DEFAULT" - The license type is the
// default for the OS.
// "COMPUTE_ENGINE_LICENSE_TYPE_PAYG" - The license type is Pay As You
// Go license type.
// "COMPUTE_ENGINE_LICENSE_TYPE_BYOL" - The license type is Bring Your
// Own License type.
LicenseType string `json:"licenseType,omitempty"`
// MachineType: The machine type to create the VM with.
MachineType string `json:"machineType,omitempty"`
// MachineTypeSeries: The machine type series to create the VM with.
MachineTypeSeries string `json:"machineTypeSeries,omitempty"`
// Metadata: The metadata key/value pairs to assign to the VM.
Metadata map[string]string `json:"metadata,omitempty"`
// NetworkInterfaces: List of NICs connected to this VM.
NetworkInterfaces []*NetworkInterface `json:"networkInterfaces,omitempty"`
// NetworkTags: A map of network tags to associate with the VM.
NetworkTags []string `json:"networkTags,omitempty"`
// Project: The GCP target project ID or project name.
Project string `json:"project,omitempty"`
// SecureBoot: Defines whether the instance has Secure Boot enabled.
// This can be set to true only if the vm boot option is EFI.
SecureBoot bool `json:"secureBoot,omitempty"`
// ServiceAccount: The service account to associate the VM with.
ServiceAccount string `json:"serviceAccount,omitempty"`
// VmName: The name of the VM to create.
VmName string `json:"vmName,omitempty"`
// Zone: The zone in which to create the VM.
Zone string `json:"zone,omitempty"`
// ForceSendFields is a list of field names (e.g. "AdditionalLicenses")
// to unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "AdditionalLicenses") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *ComputeEngineTargetDetails) MarshalJSON() ([]byte, error) {
type NoMethod ComputeEngineTargetDetails
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// ComputeScheduling: Scheduling information for VM on
// maintenance/restart behaviour and node allocation in sole tenant
// nodes.
type ComputeScheduling struct {
// MinNodeCpus: The minimum number of virtual CPUs this instance will
// consume when running on a sole-tenant node. Ignored if no
// node_affinites are configured.
MinNodeCpus int64 `json:"minNodeCpus,omitempty"`
// NodeAffinities: A set of node affinity and anti-affinity
// configurations for sole tenant nodes.
NodeAffinities []*SchedulingNodeAffinity `json:"nodeAffinities,omitempty"`
// OnHostMaintenance: How the instance should behave when the host
// machine undergoes maintenance that may temporarily impact instance
// performance.
//
// Possible values:
// "ON_HOST_MAINTENANCE_UNSPECIFIED" - An unknown, unexpected
// behavior.
// "TERMINATE" - Terminate the instance when the host machine
// undergoes maintenance.
// "MIGRATE" - Migrate the instance when the host machine undergoes
// maintenance.
OnHostMaintenance string `json:"onHostMaintenance,omitempty"`
// RestartType: Whether the Instance should be automatically restarted
// whenever it is terminated by Compute Engine (not terminated by user).
// This configuration is identical to `automaticRestart` field in
// Compute Engine create instance under scheduling. It was changed to an
// enum (instead of a boolean) to match the default value in Compute
// Engine which is automatic restart.
//
// Possible values:
// "RESTART_TYPE_UNSPECIFIED" - Unspecified behavior. This will use
// the default.
// "AUTOMATIC_RESTART" - The Instance should be automatically
// restarted whenever it is terminated by Compute Engine.
// "NO_AUTOMATIC_RESTART" - The Instance isn't automatically restarted
// whenever it is terminated by Compute Engine.
RestartType string `json:"restartType,omitempty"`
// ForceSendFields is a list of field names (e.g. "MinNodeCpus") to
// unconditionally include in API requests. By default, fields with
// empty or default 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:"-"`
// NullFields is a list of field names (e.g. "MinNodeCpus") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *ComputeScheduling) MarshalJSON() ([]byte, error) {
type NoMethod ComputeScheduling
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CutoverJob: CutoverJob message describes a cutover of a migrating VM.
// The CutoverJob is the operation of shutting down the VM, creating a
// snapshot and clonning the VM using the replicated snapshot.
type CutoverJob struct {
// ComputeEngineTargetDetails: Output only. Details of the target VM in
// Compute Engine.
ComputeEngineTargetDetails *ComputeEngineTargetDetails `json:"computeEngineTargetDetails,omitempty"`
// CreateTime: Output only. The time the cutover job was created (as an
// API call, not when it was actually created in the target).
CreateTime string `json:"createTime,omitempty"`
// EndTime: Output only. The time the cutover job had finished.
EndTime string `json:"endTime,omitempty"`
// Error: Output only. Provides details for the errors that led to the
// Cutover Job's state.
Error *Status `json:"error,omitempty"`
// Name: Output only. The name of the cutover job.
Name string `json:"name,omitempty"`
// ProgressPercent: Output only. The current progress in percentage of
// the cutover job.
ProgressPercent int64 `json:"progressPercent,omitempty"`
// State: Output only. State of the cutover job.
//
// Possible values:
// "STATE_UNSPECIFIED" - The state is unknown. This is used for API
// compatibility only and is not used by the system.
// "PENDING" - The cutover job has not yet started.
// "FAILED" - The cutover job finished with errors.
// "SUCCEEDED" - The cutover job finished successfully.
// "CANCELLED" - The cutover job was cancelled.
// "CANCELLING" - The cutover job is being cancelled.
// "ACTIVE" - The cutover job is active and running.
// "ADAPTING_OS" - OS adaptation is running as part of the cutover job
// to generate license.
State string `json:"state,omitempty"`
// StateMessage: Output only. A message providing possible extra details
// about the current state.
StateMessage string `json:"stateMessage,omitempty"`
// StateTime: Output only. The time the state was last updated.
StateTime string `json:"stateTime,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g.
// "ComputeEngineTargetDetails") to unconditionally include in API
// requests. By default, fields with empty or default 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:"-"`
// NullFields is a list of field names (e.g.
// "ComputeEngineTargetDetails") to include in API requests with the
// JSON null value. By default, fields with empty values are omitted
// from API requests. However, any field with an empty value appearing
// in NullFields will be sent to the server as null. It is an error if a
// field in this list has a non-empty value. This may be used to include
// null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *CutoverJob) MarshalJSON() ([]byte, error) {
type NoMethod CutoverJob
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// DatacenterConnector: DatacenterConnector message describes a
// connector between the Source and GCP, which is installed on a vmware
// datacenter (an OVA vm installed by the user) to connect the
// Datacenter to GCP and support vm migration data transfer.
type DatacenterConnector struct {
// ApplianceInfrastructureVersion: Output only. Appliance OVA version.
// This is the OVA which is manually installed by the user and contains
// the infrastructure for the automatically updatable components on the
// appliance.
ApplianceInfrastructureVersion string `json:"applianceInfrastructureVersion,omitempty"`
// ApplianceSoftwareVersion: Output only. Appliance last installed
// update bundle version. This is the version of the automatically
// updatable components on the appliance.
ApplianceSoftwareVersion string `json:"applianceSoftwareVersion,omitempty"`
// AvailableVersions: Output only. The available versions for updating
// this appliance.
AvailableVersions *AvailableUpdates `json:"availableVersions,omitempty"`
// Bucket: Output only. The communication channel between the datacenter
// connector and GCP.
Bucket string `json:"bucket,omitempty"`
// CreateTime: Output only. The time the connector was created (as an
// API call, not when it was actually installed).
CreateTime string `json:"createTime,omitempty"`
// Error: Output only. Provides details on the state of the Datacenter
// Connector in case of an error.
Error *Status `json:"error,omitempty"`
// Name: Output only. The connector's name.
Name string `json:"name,omitempty"`
// RegistrationId: Immutable. A unique key for this connector. This key
// is internal to the OVA connector and is supplied with its creation
// during the registration process and can not be modified.
RegistrationId string `json:"registrationId,omitempty"`
// ServiceAccount: The service account to use in the connector when
// communicating with the cloud.
ServiceAccount string `json:"serviceAccount,omitempty"`
// State: Output only. State of the DatacenterConnector, as determined
// by the health checks.
//
// Possible values:
// "STATE_UNSPECIFIED" - The state is unknown. This is used for API
// compatibility only and is not used by the system.
// "PENDING" - The state was not sampled by the health checks yet.
// "OFFLINE" - The source was sampled by health checks and is not
// available.
// "FAILED" - The source is available but might not be usable yet due
// to unvalidated credentials or another reason. The credentials
// referred to are the ones to the Source. The error message will
// contain further details.
// "ACTIVE" - The source exists and its credentials were verified.
State string `json:"state,omitempty"`
// StateTime: Output only. The time the state was last set.
StateTime string `json:"stateTime,omitempty"`
// UpdateTime: Output only. The last time the connector was updated with
// an API call.
UpdateTime string `json:"updateTime,omitempty"`
// UpgradeStatus: Output only. The status of the current / last
// upgradeAppliance operation.
UpgradeStatus *UpgradeStatus `json:"upgradeStatus,omitempty"`
// Version: The version running in the DatacenterConnector. This is
// supplied by the OVA connector during the registration process and can
// not be modified.
Version string `json:"version,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g.
// "ApplianceInfrastructureVersion") to unconditionally include in API
// requests. By default, fields with empty or default 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:"-"`
// NullFields is a list of field names (e.g.
// "ApplianceInfrastructureVersion") to include in API requests with the
// JSON null value. By default, fields with empty values are omitted
// from API requests. However, any field with an empty value appearing
// in NullFields will be sent to the server as null. It is an error if a
// field in this list has a non-empty value. This may be used to include
// null fields in Patch requests.
NullFields []string `json:"-"`