Skip to content

Commit

Permalink
feat: enable "rest" transport in Python for services supporting numer…
Browse files Browse the repository at this point in the history
…ic enums (#202)

* feat: enable "rest" transport in Python for services supporting numeric enums

PiperOrigin-RevId: 508143576

Source-Link: googleapis/googleapis@7a702a9

Source-Link: googleapis/googleapis-gen@6ad1279
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNmFkMTI3OWMwZTdhYTc4N2FjNmI2NmM5ZmQ0YTIxMDY5MmVkZmZjZCJ9

* 🦉 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>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Feb 9, 2023
1 parent 8ff2e9a commit 52d2280
Show file tree
Hide file tree
Showing 5 changed files with 6,951 additions and 85 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,86 @@
]
}
}
},
"rest": {
"libraryClient": "ApiGatewayServiceClient",
"rpcs": {
"CreateApi": {
"methods": [
"create_api"
]
},
"CreateApiConfig": {
"methods": [
"create_api_config"
]
},
"CreateGateway": {
"methods": [
"create_gateway"
]
},
"DeleteApi": {
"methods": [
"delete_api"
]
},
"DeleteApiConfig": {
"methods": [
"delete_api_config"
]
},
"DeleteGateway": {
"methods": [
"delete_gateway"
]
},
"GetApi": {
"methods": [
"get_api"
]
},
"GetApiConfig": {
"methods": [
"get_api_config"
]
},
"GetGateway": {
"methods": [
"get_gateway"
]
},
"ListApiConfigs": {
"methods": [
"list_api_configs"
]
},
"ListApis": {
"methods": [
"list_apis"
]
},
"ListGateways": {
"methods": [
"list_gateways"
]
},
"UpdateApi": {
"methods": [
"update_api"
]
},
"UpdateApiConfig": {
"methods": [
"update_api_config"
]
},
"UpdateGateway": {
"methods": [
"update_gateway"
]
}
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
from .transports.base import DEFAULT_CLIENT_INFO, ApiGatewayServiceTransport
from .transports.grpc import ApiGatewayServiceGrpcTransport
from .transports.grpc_asyncio import ApiGatewayServiceGrpcAsyncIOTransport
from .transports.rest import ApiGatewayServiceRestTransport


class ApiGatewayServiceClientMeta(type):
Expand All @@ -73,6 +74,7 @@ class ApiGatewayServiceClientMeta(type):
) # type: Dict[str, Type[ApiGatewayServiceTransport]]
_transport_registry["grpc"] = ApiGatewayServiceGrpcTransport
_transport_registry["grpc_asyncio"] = ApiGatewayServiceGrpcAsyncIOTransport
_transport_registry["rest"] = ApiGatewayServiceRestTransport

def get_transport_class(
cls,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,18 @@
from .base import ApiGatewayServiceTransport
from .grpc import ApiGatewayServiceGrpcTransport
from .grpc_asyncio import ApiGatewayServiceGrpcAsyncIOTransport
from .rest import ApiGatewayServiceRestInterceptor, ApiGatewayServiceRestTransport

# Compile a registry of transports.
_transport_registry = OrderedDict() # type: Dict[str, Type[ApiGatewayServiceTransport]]
_transport_registry["grpc"] = ApiGatewayServiceGrpcTransport
_transport_registry["grpc_asyncio"] = ApiGatewayServiceGrpcAsyncIOTransport
_transport_registry["rest"] = ApiGatewayServiceRestTransport

__all__ = (
"ApiGatewayServiceTransport",
"ApiGatewayServiceGrpcTransport",
"ApiGatewayServiceGrpcAsyncIOTransport",
"ApiGatewayServiceRestTransport",
"ApiGatewayServiceRestInterceptor",
)
Loading

0 comments on commit 52d2280

Please sign in to comment.