| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent aaf154b commit c37bf21
16 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -108,7 +108,7 @@ def __init__( | |||
| 108 | 108 | scopes_kwargs = self._get_scopes_kwargs(self._host, scopes) | |
| 109 | 109 | ||
| 110 | 110 | # Save the scopes. | |
| 111 | - self._scopes = scopes or self.AUTH_SCOPES | ||
| 111 | + self._scopes = scopes | ||
| 112 | 112 | ||
| 113 | 113 | # If no credentials are provided, then determine the appropriate | |
| 114 | 114 | # defaults. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -69,6 +69,7 @@ def __init__( | |||
| 69 | 69 | client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None, | |
| 70 | 70 | quota_project_id: Optional[str] = None, | |
| 71 | 71 | client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO, | |
| 72 | + always_use_jwt_access: Optional[bool] = False, | ||
| 72 | 73 | ) -> None: | |
| 73 | 74 | """Instantiate the transport. | |
| 74 | 75 | ||
@@ -109,6 +110,8 @@ def __init__( | |||
| 109 | 110 | API requests. If ``None``, then default info will be used. | |
| 110 | 111 | Generally, you only need to set this if you're developing | |
| 111 | 112 | your own client library. | |
| 113 | + always_use_jwt_access (Optional[bool]): Whether self signed JWT should | ||
| 114 | + be used for service account credentials. | ||
| 112 | 115 | ||
| 113 | 116 | Raises: | |
| 114 | 117 | google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport | |
@@ -162,7 +165,7 @@ def __init__( | |||
| 162 | 165 | scopes=scopes, | |
| 163 | 166 | quota_project_id=quota_project_id, | |
| 164 | 167 | client_info=client_info, | |
| 165 | - always_use_jwt_access=True, | ||
| 168 | + always_use_jwt_access=always_use_jwt_access, | ||
| 166 | 169 | ) | |
| 167 | 170 | ||
| 168 | 171 | if not self._grpc_channel: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -115,6 +115,7 @@ def __init__( | |||
| 115 | 115 | client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None, | |
| 116 | 116 | quota_project_id=None, | |
| 117 | 117 | client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO, | |
| 118 | + always_use_jwt_access: Optional[bool] = False, | ||
| 118 | 119 | ) -> None: | |
| 119 | 120 | """Instantiate the transport. | |
| 120 | 121 | ||
@@ -156,6 +157,8 @@ def __init__( | |||
| 156 | 157 | API requests. If ``None``, then default info will be used. | |
| 157 | 158 | Generally, you only need to set this if you're developing | |
| 158 | 159 | your own client library. | |
| 160 | + always_use_jwt_access (Optional[bool]): Whether self signed JWT should | ||
| 161 | + be used for service account credentials. | ||
| 159 | 162 | ||
| 160 | 163 | Raises: | |
| 161 | 164 | google.auth.exceptions.MutualTlsChannelError: If mutual TLS transport | |
@@ -208,7 +211,7 @@ def __init__( | |||
| 208 | 211 | scopes=scopes, | |
| 209 | 212 | quota_project_id=quota_project_id, | |
| 210 | 213 | client_info=client_info, | |
| 211 | - always_use_jwt_access=True, | ||
| 214 | + always_use_jwt_access=always_use_jwt_access, | ||
| 212 | 215 | ) | |
| 213 | 216 | ||
| 214 | 217 | if not self._grpc_channel: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -121,6 +121,14 @@ class Database(proto.Message): | |||
| 121 | 121 | sure to account for the time from the moment | |
| 122 | 122 | when the value is queried to the moment when you | |
| 123 | 123 | initiate the recovery. | |
| 124 | + default_leader (str): | ||
| 125 | + Output only. The read-write region which contains the | ||
| 126 | + database's leader replicas. | ||
| 127 | + | ||
| 128 | + This is the same as the value of default_leader database | ||
| 129 | + option set using DatabaseAdmin.CreateDatabase or | ||
| 130 | + DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this | ||
| 131 | + is empty. | ||
| 124 | 132 | """ | |
| 125 | 133 | ||
| 126 | 134 | class State(proto.Enum): | |
@@ -144,6 +152,7 @@ class State(proto.Enum): | |||
| 144 | 152 | earliest_version_time = proto.Field( | |
| 145 | 153 | proto.MESSAGE, number=7, message=timestamp_pb2.Timestamp, | |
| 146 | 154 | ) | |
| 155 | + default_leader = proto.Field(proto.STRING, number=9,) | ||
| 147 | 156 | ||
| 148 | 157 | ||
| 149 | 158 | class ListDatabasesRequest(proto.Message): | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -106,7 +106,7 @@ def __init__( | |||
| 106 | 106 | scopes_kwargs = self._get_scopes_kwargs(self._host, scopes) | |
| 107 | 107 | ||
| 108 | 108 | # Save the scopes. | |
| 109 | - self._scopes = scopes or self.AUTH_SCOPES | ||
| 109 | + self._scopes = scopes | ||
| 110 | 110 | ||
| 111 | 111 | # If no credentials are provided, then determine the appropriate | |
| 112 | 112 | # defaults. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -82,6 +82,7 @@ def __init__( | |||
| 82 | 82 | client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None, | |
| 83 | 83 | quota_project_id: Optional[str] = None, | |
| 84 | 84 | client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO, | |
| 85 | + always_use_jwt_access: Optional[bool] = False, | ||
| 85 | 86 | ) -> None: | |
| 86 | 87 | """Instantiate the transport. | |
| 87 | 88 | ||
@@ -122,6 +123,8 @@ def __init__( | |||
| 122 | 123 | API requests. If ``None``, then default info will be used. | |
| 123 | 124 | Generally, you only need to set this if you're developing | |
| 124 | 125 | your own client library. | |
| 126 | + always_use_jwt_access (Optional[bool]): Whether self signed JWT should | ||
| 127 | + be used for service account credentials. | ||
| 125 | 128 | ||
| 126 | 129 | Raises: | |
| 127 | 130 | google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport | |
@@ -175,7 +178,7 @@ def __init__( | |||
| 175 | 178 | scopes=scopes, | |
| 176 | 179 | quota_project_id=quota_project_id, | |
| 177 | 180 | client_info=client_info, | |
| 178 | - always_use_jwt_access=True, | ||
| 181 | + always_use_jwt_access=always_use_jwt_access, | ||
| 179 | 182 | ) | |
| 180 | 183 | ||
| 181 | 184 | if not self._grpc_channel: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -128,6 +128,7 @@ def __init__( | |||
| 128 | 128 | client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None, | |
| 129 | 129 | quota_project_id=None, | |
| 130 | 130 | client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO, | |
| 131 | + always_use_jwt_access: Optional[bool] = False, | ||
| 131 | 132 | ) -> None: | |
| 132 | 133 | """Instantiate the transport. | |
| 133 | 134 | ||
@@ -169,6 +170,8 @@ def __init__( | |||
| 169 | 170 | API requests. If ``None``, then default info will be used. | |
| 170 | 171 | Generally, you only need to set this if you're developing | |
| 171 | 172 | your own client library. | |
| 173 | + always_use_jwt_access (Optional[bool]): Whether self signed JWT should | ||
| 174 | + be used for service account credentials. | ||
| 172 | 175 | ||
| 173 | 176 | Raises: | |
| 174 | 177 | google.auth.exceptions.MutualTlsChannelError: If mutual TLS transport | |
@@ -221,7 +224,7 @@ def __init__( | |||
| 221 | 224 | scopes=scopes, | |
| 222 | 225 | quota_project_id=quota_project_id, | |
| 223 | 226 | client_info=client_info, | |
| 224 | - always_use_jwt_access=True, | ||
| 227 | + always_use_jwt_access=always_use_jwt_access, | ||
| 225 | 228 | ) | |
| 226 | 229 | ||
| 227 | 230 | if not self._grpc_channel: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -88,11 +88,15 @@ class InstanceConfig(proto.Message): | |||
| 88 | 88 | The geographic placement of nodes in this | |
| 89 | 89 | instance configuration and their replication | |
| 90 | 90 | properties. | |
| 91 | + leader_options (Sequence[str]): | ||
| 92 | + Allowed values of the “default_leader” schema option for | ||
| 93 | + databases in instances that use this instance configuration. | ||
| 91 | 94 | """ | |
| 92 | 95 | ||
| 93 | 96 | name = proto.Field(proto.STRING, number=1,) | |
| 94 | 97 | display_name = proto.Field(proto.STRING, number=2,) | |
| 95 | 98 | replicas = proto.RepeatedField(proto.MESSAGE, number=3, message="ReplicaInfo",) | |
| 99 | + leader_options = proto.RepeatedField(proto.STRING, number=4,) | ||
| 96 | 100 | ||
| 97 | 101 | ||
| 98 | 102 | class Instance(proto.Message): | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -103,7 +103,7 @@ def __init__( | |||
| 103 | 103 | scopes_kwargs = self._get_scopes_kwargs(self._host, scopes) | |
| 104 | 104 | ||
| 105 | 105 | # Save the scopes. | |
| 106 | - self._scopes = scopes or self.AUTH_SCOPES | ||
| 106 | + self._scopes = scopes | ||
| 107 | 107 | ||
| 108 | 108 | # If no credentials are provided, then determine the appropriate | |
| 109 | 109 | # defaults. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -63,6 +63,7 @@ def __init__( | |||
| 63 | 63 | client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None, | |
| 64 | 64 | quota_project_id: Optional[str] = None, | |
| 65 | 65 | client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO, | |
| 66 | + always_use_jwt_access: Optional[bool] = False, | ||
| 66 | 67 | ) -> None: | |
| 67 | 68 | """Instantiate the transport. | |
| 68 | 69 | ||
@@ -103,6 +104,8 @@ def __init__( | |||
| 103 | 104 | API requests. If ``None``, then default info will be used. | |
| 104 | 105 | Generally, you only need to set this if you're developing | |
| 105 | 106 | your own client library. | |
| 107 | + always_use_jwt_access (Optional[bool]): Whether self signed JWT should | ||
| 108 | + be used for service account credentials. | ||
| 106 | 109 | ||
| 107 | 110 | Raises: | |
| 108 | 111 | google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport | |
@@ -155,7 +158,7 @@ def __init__( | |||
| 155 | 158 | scopes=scopes, | |
| 156 | 159 | quota_project_id=quota_project_id, | |
| 157 | 160 | client_info=client_info, | |
| 158 | - always_use_jwt_access=True, | ||
| 161 | + always_use_jwt_access=always_use_jwt_access, | ||
| 159 | 162 | ) | |
| 160 | 163 | ||
| 161 | 164 | if not self._grpc_channel: | |
| Back | FazBrowse Home | New Git URL |
0 commit comments