Skip to content
This repository was archived by the owner on Jul 6, 2023. It is now read-only.

Commit f6d145d

Browse files
feat: enable "rest" transport in Python for services supporting numeric enums (#113)
* feat: enable "rest" transport in Python for services supporting numeric enums PiperOrigin-RevId: 508143576 Source-Link: googleapis/googleapis@7a702a9 Source-Link: https://github.com/googleapis/googleapis-gen/commit/6ad1279c0e7aa787ac6b66c9fd4a210692edffcd Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNmFkMTI3OWMwZTdhYTc4N2FjNmI2NmM5ZmQ0YTIxMDY5MmVkZmZjZCJ9 * feat: enable "rest" transport in Python for services supporting numeric enums PiperOrigin-RevId: 508143576 Source-Link: googleapis/googleapis@7a702a9 Source-Link: https://github.com/googleapis/googleapis-gen/commit/6ad1279c0e7aa787ac6b66c9fd4a210692edffcd Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNmFkMTI3OWMwZTdhYTc4N2FjNmI2NmM5ZmQ0YTIxMDY5MmVkZmZjZCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 951e8a7 commit f6d145d

File tree

5 files changed

+22815
-93
lines changed

5 files changed

+22815
-93
lines changed

google/cloud/vmmigration_v1/gapic_metadata.json

Lines changed: 235 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,241 @@
476476
]
477477
}
478478
}
479+
},
480+
"rest": {
481+
"libraryClient": "VmMigrationClient",
482+
"rpcs": {
483+
"AddGroupMigration": {
484+
"methods": [
485+
"add_group_migration"
486+
]
487+
},
488+
"CancelCloneJob": {
489+
"methods": [
490+
"cancel_clone_job"
491+
]
492+
},
493+
"CancelCutoverJob": {
494+
"methods": [
495+
"cancel_cutover_job"
496+
]
497+
},
498+
"CreateCloneJob": {
499+
"methods": [
500+
"create_clone_job"
501+
]
502+
},
503+
"CreateCutoverJob": {
504+
"methods": [
505+
"create_cutover_job"
506+
]
507+
},
508+
"CreateDatacenterConnector": {
509+
"methods": [
510+
"create_datacenter_connector"
511+
]
512+
},
513+
"CreateGroup": {
514+
"methods": [
515+
"create_group"
516+
]
517+
},
518+
"CreateMigratingVm": {
519+
"methods": [
520+
"create_migrating_vm"
521+
]
522+
},
523+
"CreateSource": {
524+
"methods": [
525+
"create_source"
526+
]
527+
},
528+
"CreateTargetProject": {
529+
"methods": [
530+
"create_target_project"
531+
]
532+
},
533+
"CreateUtilizationReport": {
534+
"methods": [
535+
"create_utilization_report"
536+
]
537+
},
538+
"DeleteDatacenterConnector": {
539+
"methods": [
540+
"delete_datacenter_connector"
541+
]
542+
},
543+
"DeleteGroup": {
544+
"methods": [
545+
"delete_group"
546+
]
547+
},
548+
"DeleteMigratingVm": {
549+
"methods": [
550+
"delete_migrating_vm"
551+
]
552+
},
553+
"DeleteSource": {
554+
"methods": [
555+
"delete_source"
556+
]
557+
},
558+
"DeleteTargetProject": {
559+
"methods": [
560+
"delete_target_project"
561+
]
562+
},
563+
"DeleteUtilizationReport": {
564+
"methods": [
565+
"delete_utilization_report"
566+
]
567+
},
568+
"FetchInventory": {
569+
"methods": [
570+
"fetch_inventory"
571+
]
572+
},
573+
"FinalizeMigration": {
574+
"methods": [
575+
"finalize_migration"
576+
]
577+
},
578+
"GetCloneJob": {
579+
"methods": [
580+
"get_clone_job"
581+
]
582+
},
583+
"GetCutoverJob": {
584+
"methods": [
585+
"get_cutover_job"
586+
]
587+
},
588+
"GetDatacenterConnector": {
589+
"methods": [
590+
"get_datacenter_connector"
591+
]
592+
},
593+
"GetGroup": {
594+
"methods": [
595+
"get_group"
596+
]
597+
},
598+
"GetMigratingVm": {
599+
"methods": [
600+
"get_migrating_vm"
601+
]
602+
},
603+
"GetReplicationCycle": {
604+
"methods": [
605+
"get_replication_cycle"
606+
]
607+
},
608+
"GetSource": {
609+
"methods": [
610+
"get_source"
611+
]
612+
},
613+
"GetTargetProject": {
614+
"methods": [
615+
"get_target_project"
616+
]
617+
},
618+
"GetUtilizationReport": {
619+
"methods": [
620+
"get_utilization_report"
621+
]
622+
},
623+
"ListCloneJobs": {
624+
"methods": [
625+
"list_clone_jobs"
626+
]
627+
},
628+
"ListCutoverJobs": {
629+
"methods": [
630+
"list_cutover_jobs"
631+
]
632+
},
633+
"ListDatacenterConnectors": {
634+
"methods": [
635+
"list_datacenter_connectors"
636+
]
637+
},
638+
"ListGroups": {
639+
"methods": [
640+
"list_groups"
641+
]
642+
},
643+
"ListMigratingVms": {
644+
"methods": [
645+
"list_migrating_vms"
646+
]
647+
},
648+
"ListReplicationCycles": {
649+
"methods": [
650+
"list_replication_cycles"
651+
]
652+
},
653+
"ListSources": {
654+
"methods": [
655+
"list_sources"
656+
]
657+
},
658+
"ListTargetProjects": {
659+
"methods": [
660+
"list_target_projects"
661+
]
662+
},
663+
"ListUtilizationReports": {
664+
"methods": [
665+
"list_utilization_reports"
666+
]
667+
},
668+
"PauseMigration": {
669+
"methods": [
670+
"pause_migration"
671+
]
672+
},
673+
"RemoveGroupMigration": {
674+
"methods": [
675+
"remove_group_migration"
676+
]
677+
},
678+
"ResumeMigration": {
679+
"methods": [
680+
"resume_migration"
681+
]
682+
},
683+
"StartMigration": {
684+
"methods": [
685+
"start_migration"
686+
]
687+
},
688+
"UpdateGroup": {
689+
"methods": [
690+
"update_group"
691+
]
692+
},
693+
"UpdateMigratingVm": {
694+
"methods": [
695+
"update_migrating_vm"
696+
]
697+
},
698+
"UpdateSource": {
699+
"methods": [
700+
"update_source"
701+
]
702+
},
703+
"UpdateTargetProject": {
704+
"methods": [
705+
"update_target_project"
706+
]
707+
},
708+
"UpgradeAppliance": {
709+
"methods": [
710+
"upgrade_appliance"
711+
]
712+
}
713+
}
479714
}
480715
}
481716
}

google/cloud/vmmigration_v1/services/vm_migration/client.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@
6464
from .transports.base import DEFAULT_CLIENT_INFO, VmMigrationTransport
6565
from .transports.grpc import VmMigrationGrpcTransport
6666
from .transports.grpc_asyncio import VmMigrationGrpcAsyncIOTransport
67+
from .transports.rest import VmMigrationRestTransport
6768

6869

6970
class VmMigrationClientMeta(type):
@@ -77,6 +78,7 @@ class VmMigrationClientMeta(type):
7778
_transport_registry = OrderedDict() # type: Dict[str, Type[VmMigrationTransport]]
7879
_transport_registry["grpc"] = VmMigrationGrpcTransport
7980
_transport_registry["grpc_asyncio"] = VmMigrationGrpcAsyncIOTransport
81+
_transport_registry["rest"] = VmMigrationRestTransport
8082

8183
def get_transport_class(
8284
cls,

google/cloud/vmmigration_v1/services/vm_migration/transports/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,18 @@
1919
from .base import VmMigrationTransport
2020
from .grpc import VmMigrationGrpcTransport
2121
from .grpc_asyncio import VmMigrationGrpcAsyncIOTransport
22+
from .rest import VmMigrationRestInterceptor, VmMigrationRestTransport
2223

2324
# Compile a registry of transports.
2425
_transport_registry = OrderedDict() # type: Dict[str, Type[VmMigrationTransport]]
2526
_transport_registry["grpc"] = VmMigrationGrpcTransport
2627
_transport_registry["grpc_asyncio"] = VmMigrationGrpcAsyncIOTransport
28+
_transport_registry["rest"] = VmMigrationRestTransport
2729

2830
__all__ = (
2931
"VmMigrationTransport",
3032
"VmMigrationGrpcTransport",
3133
"VmMigrationGrpcAsyncIOTransport",
34+
"VmMigrationRestTransport",
35+
"VmMigrationRestInterceptor",
3236
)

0 commit comments

Comments
 (0)