google-cloud-securesourcemanager 0.1.6__tar.gz → 0.1.8__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {google-cloud-securesourcemanager-0.1.6/google_cloud_securesourcemanager.egg-info → google_cloud_securesourcemanager-0.1.8}/PKG-INFO +1 -1
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager/gapic_version.py +1 -1
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/gapic_version.py +1 -1
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/async_client.py +12 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/client.py +48 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/pagers.py +66 -4
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/types/secure_source_manager.py +55 -2
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8/google_cloud_securesourcemanager.egg-info}/PKG-INFO +1 -1
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/unit/gapic/securesourcemanager_v1/test_secure_source_manager.py +90 -21
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/LICENSE +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/MANIFEST.in +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/README.rst +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager/py.typed +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/gapic_metadata.json +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/py.typed +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/transports/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/transports/base.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/transports/grpc.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/transports/grpc_asyncio.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/services/secure_source_manager/transports/rest.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google/cloud/securesourcemanager_v1/types/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google_cloud_securesourcemanager.egg-info/SOURCES.txt +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google_cloud_securesourcemanager.egg-info/dependency_links.txt +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google_cloud_securesourcemanager.egg-info/not-zip-safe +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google_cloud_securesourcemanager.egg-info/requires.txt +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/google_cloud_securesourcemanager.egg-info/top_level.txt +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/setup.cfg +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/setup.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/unit/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/unit/gapic/__init__.py +0 -0
- {google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/unit/gapic/securesourcemanager_v1/__init__.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: google-cloud-securesourcemanager
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.8
|
|
4
4
|
Summary: Google Cloud Securesourcemanager API client library
|
|
5
5
|
Home-page: https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-securesourcemanager
|
|
6
6
|
Author: Google LLC
|
|
@@ -97,6 +97,8 @@ class SecureSourceManagerAsyncClient:
|
|
|
97
97
|
_DEFAULT_ENDPOINT_TEMPLATE = SecureSourceManagerClient._DEFAULT_ENDPOINT_TEMPLATE
|
|
98
98
|
_DEFAULT_UNIVERSE = SecureSourceManagerClient._DEFAULT_UNIVERSE
|
|
99
99
|
|
|
100
|
+
ca_pool_path = staticmethod(SecureSourceManagerClient.ca_pool_path)
|
|
101
|
+
parse_ca_pool_path = staticmethod(SecureSourceManagerClient.parse_ca_pool_path)
|
|
100
102
|
crypto_key_path = staticmethod(SecureSourceManagerClient.crypto_key_path)
|
|
101
103
|
parse_crypto_key_path = staticmethod(
|
|
102
104
|
SecureSourceManagerClient.parse_crypto_key_path
|
|
@@ -107,6 +109,12 @@ class SecureSourceManagerAsyncClient:
|
|
|
107
109
|
parse_repository_path = staticmethod(
|
|
108
110
|
SecureSourceManagerClient.parse_repository_path
|
|
109
111
|
)
|
|
112
|
+
service_attachment_path = staticmethod(
|
|
113
|
+
SecureSourceManagerClient.service_attachment_path
|
|
114
|
+
)
|
|
115
|
+
parse_service_attachment_path = staticmethod(
|
|
116
|
+
SecureSourceManagerClient.parse_service_attachment_path
|
|
117
|
+
)
|
|
110
118
|
common_billing_account_path = staticmethod(
|
|
111
119
|
SecureSourceManagerClient.common_billing_account_path
|
|
112
120
|
)
|
|
@@ -417,6 +425,8 @@ class SecureSourceManagerAsyncClient:
|
|
|
417
425
|
method=rpc,
|
|
418
426
|
request=request,
|
|
419
427
|
response=response,
|
|
428
|
+
retry=retry,
|
|
429
|
+
timeout=timeout,
|
|
420
430
|
metadata=metadata,
|
|
421
431
|
)
|
|
422
432
|
|
|
@@ -912,6 +922,8 @@ class SecureSourceManagerAsyncClient:
|
|
|
912
922
|
method=rpc,
|
|
913
923
|
request=request,
|
|
914
924
|
response=response,
|
|
925
|
+
retry=retry,
|
|
926
|
+
timeout=timeout,
|
|
915
927
|
metadata=metadata,
|
|
916
928
|
)
|
|
917
929
|
|
|
@@ -217,6 +217,28 @@ class SecureSourceManagerClient(metaclass=SecureSourceManagerClientMeta):
|
|
|
217
217
|
"""
|
|
218
218
|
return self._transport
|
|
219
219
|
|
|
220
|
+
@staticmethod
|
|
221
|
+
def ca_pool_path(
|
|
222
|
+
project: str,
|
|
223
|
+
location: str,
|
|
224
|
+
ca_pool: str,
|
|
225
|
+
) -> str:
|
|
226
|
+
"""Returns a fully-qualified ca_pool string."""
|
|
227
|
+
return "projects/{project}/locations/{location}/caPools/{ca_pool}".format(
|
|
228
|
+
project=project,
|
|
229
|
+
location=location,
|
|
230
|
+
ca_pool=ca_pool,
|
|
231
|
+
)
|
|
232
|
+
|
|
233
|
+
@staticmethod
|
|
234
|
+
def parse_ca_pool_path(path: str) -> Dict[str, str]:
|
|
235
|
+
"""Parses a ca_pool path into its component segments."""
|
|
236
|
+
m = re.match(
|
|
237
|
+
r"^projects/(?P<project>.+?)/locations/(?P<location>.+?)/caPools/(?P<ca_pool>.+?)$",
|
|
238
|
+
path,
|
|
239
|
+
)
|
|
240
|
+
return m.groupdict() if m else {}
|
|
241
|
+
|
|
220
242
|
@staticmethod
|
|
221
243
|
def crypto_key_path(
|
|
222
244
|
project: str,
|
|
@@ -287,6 +309,28 @@ class SecureSourceManagerClient(metaclass=SecureSourceManagerClientMeta):
|
|
|
287
309
|
)
|
|
288
310
|
return m.groupdict() if m else {}
|
|
289
311
|
|
|
312
|
+
@staticmethod
|
|
313
|
+
def service_attachment_path(
|
|
314
|
+
project: str,
|
|
315
|
+
region: str,
|
|
316
|
+
service_attachment: str,
|
|
317
|
+
) -> str:
|
|
318
|
+
"""Returns a fully-qualified service_attachment string."""
|
|
319
|
+
return "projects/{project}/regions/{region}/serviceAttachments/{service_attachment}".format(
|
|
320
|
+
project=project,
|
|
321
|
+
region=region,
|
|
322
|
+
service_attachment=service_attachment,
|
|
323
|
+
)
|
|
324
|
+
|
|
325
|
+
@staticmethod
|
|
326
|
+
def parse_service_attachment_path(path: str) -> Dict[str, str]:
|
|
327
|
+
"""Parses a service_attachment path into its component segments."""
|
|
328
|
+
m = re.match(
|
|
329
|
+
r"^projects/(?P<project>.+?)/regions/(?P<region>.+?)/serviceAttachments/(?P<service_attachment>.+?)$",
|
|
330
|
+
path,
|
|
331
|
+
)
|
|
332
|
+
return m.groupdict() if m else {}
|
|
333
|
+
|
|
290
334
|
@staticmethod
|
|
291
335
|
def common_billing_account_path(
|
|
292
336
|
billing_account: str,
|
|
@@ -874,6 +918,8 @@ class SecureSourceManagerClient(metaclass=SecureSourceManagerClientMeta):
|
|
|
874
918
|
method=rpc,
|
|
875
919
|
request=request,
|
|
876
920
|
response=response,
|
|
921
|
+
retry=retry,
|
|
922
|
+
timeout=timeout,
|
|
877
923
|
metadata=metadata,
|
|
878
924
|
)
|
|
879
925
|
|
|
@@ -1357,6 +1403,8 @@ class SecureSourceManagerClient(metaclass=SecureSourceManagerClientMeta):
|
|
|
1357
1403
|
method=rpc,
|
|
1358
1404
|
request=request,
|
|
1359
1405
|
response=response,
|
|
1406
|
+
retry=retry,
|
|
1407
|
+
timeout=timeout,
|
|
1360
1408
|
metadata=metadata,
|
|
1361
1409
|
)
|
|
1362
1410
|
|
|
@@ -22,8 +22,22 @@ from typing import (
|
|
|
22
22
|
Optional,
|
|
23
23
|
Sequence,
|
|
24
24
|
Tuple,
|
|
25
|
+
Union,
|
|
25
26
|
)
|
|
26
27
|
|
|
28
|
+
from google.api_core import gapic_v1
|
|
29
|
+
from google.api_core import retry as retries
|
|
30
|
+
from google.api_core import retry_async as retries_async
|
|
31
|
+
|
|
32
|
+
try:
|
|
33
|
+
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault, None]
|
|
34
|
+
OptionalAsyncRetry = Union[
|
|
35
|
+
retries_async.AsyncRetry, gapic_v1.method._MethodDefault, None
|
|
36
|
+
]
|
|
37
|
+
except AttributeError: # pragma: NO COVER
|
|
38
|
+
OptionalRetry = Union[retries.Retry, object, None] # type: ignore
|
|
39
|
+
OptionalAsyncRetry = Union[retries_async.AsyncRetry, object, None] # type: ignore
|
|
40
|
+
|
|
27
41
|
from google.cloud.securesourcemanager_v1.types import secure_source_manager
|
|
28
42
|
|
|
29
43
|
|
|
@@ -51,6 +65,8 @@ class ListInstancesPager:
|
|
|
51
65
|
request: secure_source_manager.ListInstancesRequest,
|
|
52
66
|
response: secure_source_manager.ListInstancesResponse,
|
|
53
67
|
*,
|
|
68
|
+
retry: OptionalRetry = gapic_v1.method.DEFAULT,
|
|
69
|
+
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
54
70
|
metadata: Sequence[Tuple[str, str]] = ()
|
|
55
71
|
):
|
|
56
72
|
"""Instantiate the pager.
|
|
@@ -62,12 +78,17 @@ class ListInstancesPager:
|
|
|
62
78
|
The initial request object.
|
|
63
79
|
response (google.cloud.securesourcemanager_v1.types.ListInstancesResponse):
|
|
64
80
|
The initial response object.
|
|
81
|
+
retry (google.api_core.retry.Retry): Designation of what errors,
|
|
82
|
+
if any, should be retried.
|
|
83
|
+
timeout (float): The timeout for this request.
|
|
65
84
|
metadata (Sequence[Tuple[str, str]]): Strings which should be
|
|
66
85
|
sent along with the request as metadata.
|
|
67
86
|
"""
|
|
68
87
|
self._method = method
|
|
69
88
|
self._request = secure_source_manager.ListInstancesRequest(request)
|
|
70
89
|
self._response = response
|
|
90
|
+
self._retry = retry
|
|
91
|
+
self._timeout = timeout
|
|
71
92
|
self._metadata = metadata
|
|
72
93
|
|
|
73
94
|
def __getattr__(self, name: str) -> Any:
|
|
@@ -78,7 +99,12 @@ class ListInstancesPager:
|
|
|
78
99
|
yield self._response
|
|
79
100
|
while self._response.next_page_token:
|
|
80
101
|
self._request.page_token = self._response.next_page_token
|
|
81
|
-
self._response = self._method(
|
|
102
|
+
self._response = self._method(
|
|
103
|
+
self._request,
|
|
104
|
+
retry=self._retry,
|
|
105
|
+
timeout=self._timeout,
|
|
106
|
+
metadata=self._metadata,
|
|
107
|
+
)
|
|
82
108
|
yield self._response
|
|
83
109
|
|
|
84
110
|
def __iter__(self) -> Iterator[secure_source_manager.Instance]:
|
|
@@ -113,6 +139,8 @@ class ListInstancesAsyncPager:
|
|
|
113
139
|
request: secure_source_manager.ListInstancesRequest,
|
|
114
140
|
response: secure_source_manager.ListInstancesResponse,
|
|
115
141
|
*,
|
|
142
|
+
retry: OptionalAsyncRetry = gapic_v1.method.DEFAULT,
|
|
143
|
+
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
116
144
|
metadata: Sequence[Tuple[str, str]] = ()
|
|
117
145
|
):
|
|
118
146
|
"""Instantiates the pager.
|
|
@@ -124,12 +152,17 @@ class ListInstancesAsyncPager:
|
|
|
124
152
|
The initial request object.
|
|
125
153
|
response (google.cloud.securesourcemanager_v1.types.ListInstancesResponse):
|
|
126
154
|
The initial response object.
|
|
155
|
+
retry (google.api_core.retry.AsyncRetry): Designation of what errors,
|
|
156
|
+
if any, should be retried.
|
|
157
|
+
timeout (float): The timeout for this request.
|
|
127
158
|
metadata (Sequence[Tuple[str, str]]): Strings which should be
|
|
128
159
|
sent along with the request as metadata.
|
|
129
160
|
"""
|
|
130
161
|
self._method = method
|
|
131
162
|
self._request = secure_source_manager.ListInstancesRequest(request)
|
|
132
163
|
self._response = response
|
|
164
|
+
self._retry = retry
|
|
165
|
+
self._timeout = timeout
|
|
133
166
|
self._metadata = metadata
|
|
134
167
|
|
|
135
168
|
def __getattr__(self, name: str) -> Any:
|
|
@@ -140,7 +173,12 @@ class ListInstancesAsyncPager:
|
|
|
140
173
|
yield self._response
|
|
141
174
|
while self._response.next_page_token:
|
|
142
175
|
self._request.page_token = self._response.next_page_token
|
|
143
|
-
self._response = await self._method(
|
|
176
|
+
self._response = await self._method(
|
|
177
|
+
self._request,
|
|
178
|
+
retry=self._retry,
|
|
179
|
+
timeout=self._timeout,
|
|
180
|
+
metadata=self._metadata,
|
|
181
|
+
)
|
|
144
182
|
yield self._response
|
|
145
183
|
|
|
146
184
|
def __aiter__(self) -> AsyncIterator[secure_source_manager.Instance]:
|
|
@@ -179,6 +217,8 @@ class ListRepositoriesPager:
|
|
|
179
217
|
request: secure_source_manager.ListRepositoriesRequest,
|
|
180
218
|
response: secure_source_manager.ListRepositoriesResponse,
|
|
181
219
|
*,
|
|
220
|
+
retry: OptionalRetry = gapic_v1.method.DEFAULT,
|
|
221
|
+
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
182
222
|
metadata: Sequence[Tuple[str, str]] = ()
|
|
183
223
|
):
|
|
184
224
|
"""Instantiate the pager.
|
|
@@ -190,12 +230,17 @@ class ListRepositoriesPager:
|
|
|
190
230
|
The initial request object.
|
|
191
231
|
response (google.cloud.securesourcemanager_v1.types.ListRepositoriesResponse):
|
|
192
232
|
The initial response object.
|
|
233
|
+
retry (google.api_core.retry.Retry): Designation of what errors,
|
|
234
|
+
if any, should be retried.
|
|
235
|
+
timeout (float): The timeout for this request.
|
|
193
236
|
metadata (Sequence[Tuple[str, str]]): Strings which should be
|
|
194
237
|
sent along with the request as metadata.
|
|
195
238
|
"""
|
|
196
239
|
self._method = method
|
|
197
240
|
self._request = secure_source_manager.ListRepositoriesRequest(request)
|
|
198
241
|
self._response = response
|
|
242
|
+
self._retry = retry
|
|
243
|
+
self._timeout = timeout
|
|
199
244
|
self._metadata = metadata
|
|
200
245
|
|
|
201
246
|
def __getattr__(self, name: str) -> Any:
|
|
@@ -206,7 +251,12 @@ class ListRepositoriesPager:
|
|
|
206
251
|
yield self._response
|
|
207
252
|
while self._response.next_page_token:
|
|
208
253
|
self._request.page_token = self._response.next_page_token
|
|
209
|
-
self._response = self._method(
|
|
254
|
+
self._response = self._method(
|
|
255
|
+
self._request,
|
|
256
|
+
retry=self._retry,
|
|
257
|
+
timeout=self._timeout,
|
|
258
|
+
metadata=self._metadata,
|
|
259
|
+
)
|
|
210
260
|
yield self._response
|
|
211
261
|
|
|
212
262
|
def __iter__(self) -> Iterator[secure_source_manager.Repository]:
|
|
@@ -243,6 +293,8 @@ class ListRepositoriesAsyncPager:
|
|
|
243
293
|
request: secure_source_manager.ListRepositoriesRequest,
|
|
244
294
|
response: secure_source_manager.ListRepositoriesResponse,
|
|
245
295
|
*,
|
|
296
|
+
retry: OptionalAsyncRetry = gapic_v1.method.DEFAULT,
|
|
297
|
+
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
246
298
|
metadata: Sequence[Tuple[str, str]] = ()
|
|
247
299
|
):
|
|
248
300
|
"""Instantiates the pager.
|
|
@@ -254,12 +306,17 @@ class ListRepositoriesAsyncPager:
|
|
|
254
306
|
The initial request object.
|
|
255
307
|
response (google.cloud.securesourcemanager_v1.types.ListRepositoriesResponse):
|
|
256
308
|
The initial response object.
|
|
309
|
+
retry (google.api_core.retry.AsyncRetry): Designation of what errors,
|
|
310
|
+
if any, should be retried.
|
|
311
|
+
timeout (float): The timeout for this request.
|
|
257
312
|
metadata (Sequence[Tuple[str, str]]): Strings which should be
|
|
258
313
|
sent along with the request as metadata.
|
|
259
314
|
"""
|
|
260
315
|
self._method = method
|
|
261
316
|
self._request = secure_source_manager.ListRepositoriesRequest(request)
|
|
262
317
|
self._response = response
|
|
318
|
+
self._retry = retry
|
|
319
|
+
self._timeout = timeout
|
|
263
320
|
self._metadata = metadata
|
|
264
321
|
|
|
265
322
|
def __getattr__(self, name: str) -> Any:
|
|
@@ -272,7 +329,12 @@ class ListRepositoriesAsyncPager:
|
|
|
272
329
|
yield self._response
|
|
273
330
|
while self._response.next_page_token:
|
|
274
331
|
self._request.page_token = self._response.next_page_token
|
|
275
|
-
self._response = await self._method(
|
|
332
|
+
self._response = await self._method(
|
|
333
|
+
self._request,
|
|
334
|
+
retry=self._retry,
|
|
335
|
+
timeout=self._timeout,
|
|
336
|
+
metadata=self._metadata,
|
|
337
|
+
)
|
|
276
338
|
yield self._response
|
|
277
339
|
|
|
278
340
|
def __aiter__(self) -> AsyncIterator[secure_source_manager.Repository]:
|
|
@@ -64,6 +64,9 @@ class Instance(proto.Message):
|
|
|
64
64
|
Output only. Update timestamp.
|
|
65
65
|
labels (MutableMapping[str, str]):
|
|
66
66
|
Optional. Labels as key value pairs.
|
|
67
|
+
private_config (google.cloud.securesourcemanager_v1.types.Instance.PrivateConfig):
|
|
68
|
+
Optional. Private settings for private
|
|
69
|
+
instance.
|
|
67
70
|
state (google.cloud.securesourcemanager_v1.types.Instance.State):
|
|
68
71
|
Output only. Current state of the instance.
|
|
69
72
|
state_note (google.cloud.securesourcemanager_v1.types.Instance.StateNote):
|
|
@@ -93,12 +96,16 @@ class Instance(proto.Message):
|
|
|
93
96
|
Instance is being deleted.
|
|
94
97
|
PAUSED (4):
|
|
95
98
|
Instance is paused.
|
|
99
|
+
UNKNOWN (6):
|
|
100
|
+
Instance is unknown, we are not sure if it's
|
|
101
|
+
functioning.
|
|
96
102
|
"""
|
|
97
103
|
STATE_UNSPECIFIED = 0
|
|
98
104
|
CREATING = 1
|
|
99
105
|
ACTIVE = 2
|
|
100
106
|
DELETING = 3
|
|
101
107
|
PAUSED = 4
|
|
108
|
+
UNKNOWN = 6
|
|
102
109
|
|
|
103
110
|
class StateNote(proto.Enum):
|
|
104
111
|
r"""Provides information about the current instance state.
|
|
@@ -148,6 +155,44 @@ class Instance(proto.Message):
|
|
|
148
155
|
number=4,
|
|
149
156
|
)
|
|
150
157
|
|
|
158
|
+
class PrivateConfig(proto.Message):
|
|
159
|
+
r"""PrivateConfig includes settings for private instance.
|
|
160
|
+
|
|
161
|
+
Attributes:
|
|
162
|
+
is_private (bool):
|
|
163
|
+
Required. Immutable. Indicate if it's private
|
|
164
|
+
instance.
|
|
165
|
+
ca_pool (str):
|
|
166
|
+
Required. Immutable. CA pool resource, resource must in the
|
|
167
|
+
format of
|
|
168
|
+
``projects/{project}/locations/{location}/caPools/{ca_pool}``.
|
|
169
|
+
http_service_attachment (str):
|
|
170
|
+
Output only. Service Attachment for HTTP, resource is in the
|
|
171
|
+
format of
|
|
172
|
+
``projects/{project}/regions/{region}/serviceAttachments/{service_attachment}``.
|
|
173
|
+
ssh_service_attachment (str):
|
|
174
|
+
Output only. Service Attachment for SSH, resource is in the
|
|
175
|
+
format of
|
|
176
|
+
``projects/{project}/regions/{region}/serviceAttachments/{service_attachment}``.
|
|
177
|
+
"""
|
|
178
|
+
|
|
179
|
+
is_private: bool = proto.Field(
|
|
180
|
+
proto.BOOL,
|
|
181
|
+
number=1,
|
|
182
|
+
)
|
|
183
|
+
ca_pool: str = proto.Field(
|
|
184
|
+
proto.STRING,
|
|
185
|
+
number=2,
|
|
186
|
+
)
|
|
187
|
+
http_service_attachment: str = proto.Field(
|
|
188
|
+
proto.STRING,
|
|
189
|
+
number=3,
|
|
190
|
+
)
|
|
191
|
+
ssh_service_attachment: str = proto.Field(
|
|
192
|
+
proto.STRING,
|
|
193
|
+
number=4,
|
|
194
|
+
)
|
|
195
|
+
|
|
151
196
|
name: str = proto.Field(
|
|
152
197
|
proto.STRING,
|
|
153
198
|
number=1,
|
|
@@ -167,6 +212,11 @@ class Instance(proto.Message):
|
|
|
167
212
|
proto.STRING,
|
|
168
213
|
number=4,
|
|
169
214
|
)
|
|
215
|
+
private_config: PrivateConfig = proto.Field(
|
|
216
|
+
proto.MESSAGE,
|
|
217
|
+
number=13,
|
|
218
|
+
message=PrivateConfig,
|
|
219
|
+
)
|
|
170
220
|
state: State = proto.Field(
|
|
171
221
|
proto.ENUM,
|
|
172
222
|
number=5,
|
|
@@ -200,9 +250,12 @@ class Repository(proto.Message):
|
|
|
200
250
|
Optional. Description of the repository,
|
|
201
251
|
which cannot exceed 500 characters.
|
|
202
252
|
instance (str):
|
|
203
|
-
|
|
204
|
-
|
|
253
|
+
Optional. The name of the instance in which the repository
|
|
254
|
+
is hosted, formatted as
|
|
205
255
|
``projects/{project_number}/locations/{location_id}/instances/{instance_id}``
|
|
256
|
+
For data plane CreateRepository requests, this field is
|
|
257
|
+
output only. For control plane CreateRepository requests,
|
|
258
|
+
this field is used as input.
|
|
206
259
|
uid (str):
|
|
207
260
|
Output only. Unique identifier of the
|
|
208
261
|
repository.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: google-cloud-securesourcemanager
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.8
|
|
4
4
|
Summary: Google Cloud Securesourcemanager API client library
|
|
5
5
|
Home-page: https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-securesourcemanager
|
|
6
6
|
Author: Google LLC
|
|
@@ -38,6 +38,7 @@ from google.api_core import (
|
|
|
38
38
|
from google.api_core import api_core_version, client_options
|
|
39
39
|
from google.api_core import exceptions as core_exceptions
|
|
40
40
|
from google.api_core import operation_async # type: ignore
|
|
41
|
+
from google.api_core import retry as retries
|
|
41
42
|
import google.auth
|
|
42
43
|
from google.auth import credentials as ga_credentials
|
|
43
44
|
from google.auth.exceptions import MutualTLSChannelError
|
|
@@ -1616,12 +1617,16 @@ def test_list_instances_pager(transport_name: str = "grpc"):
|
|
|
1616
1617
|
)
|
|
1617
1618
|
|
|
1618
1619
|
expected_metadata = ()
|
|
1620
|
+
retry = retries.Retry()
|
|
1621
|
+
timeout = 5
|
|
1619
1622
|
expected_metadata = tuple(expected_metadata) + (
|
|
1620
1623
|
gapic_v1.routing_header.to_grpc_metadata((("parent", ""),)),
|
|
1621
1624
|
)
|
|
1622
|
-
pager = client.list_instances(request={})
|
|
1625
|
+
pager = client.list_instances(request={}, retry=retry, timeout=timeout)
|
|
1623
1626
|
|
|
1624
1627
|
assert pager._metadata == expected_metadata
|
|
1628
|
+
assert pager._retry == retry
|
|
1629
|
+
assert pager._timeout == timeout
|
|
1625
1630
|
|
|
1626
1631
|
results = list(pager)
|
|
1627
1632
|
assert len(results) == 6
|
|
@@ -3339,12 +3344,16 @@ def test_list_repositories_pager(transport_name: str = "grpc"):
|
|
|
3339
3344
|
)
|
|
3340
3345
|
|
|
3341
3346
|
expected_metadata = ()
|
|
3347
|
+
retry = retries.Retry()
|
|
3348
|
+
timeout = 5
|
|
3342
3349
|
expected_metadata = tuple(expected_metadata) + (
|
|
3343
3350
|
gapic_v1.routing_header.to_grpc_metadata((("parent", ""),)),
|
|
3344
3351
|
)
|
|
3345
|
-
pager = client.list_repositories(request={})
|
|
3352
|
+
pager = client.list_repositories(request={}, retry=retry, timeout=timeout)
|
|
3346
3353
|
|
|
3347
3354
|
assert pager._metadata == expected_metadata
|
|
3355
|
+
assert pager._retry == retry
|
|
3356
|
+
assert pager._timeout == timeout
|
|
3348
3357
|
|
|
3349
3358
|
results = list(pager)
|
|
3350
3359
|
assert len(results) == 6
|
|
@@ -6607,6 +6616,12 @@ def test_create_instance_rest(request_type):
|
|
|
6607
6616
|
"create_time": {"seconds": 751, "nanos": 543},
|
|
6608
6617
|
"update_time": {},
|
|
6609
6618
|
"labels": {},
|
|
6619
|
+
"private_config": {
|
|
6620
|
+
"is_private": True,
|
|
6621
|
+
"ca_pool": "ca_pool_value",
|
|
6622
|
+
"http_service_attachment": "http_service_attachment_value",
|
|
6623
|
+
"ssh_service_attachment": "ssh_service_attachment_value",
|
|
6624
|
+
},
|
|
6610
6625
|
"state": 1,
|
|
6611
6626
|
"state_note": 1,
|
|
6612
6627
|
"kms_key": "kms_key_value",
|
|
@@ -10302,11 +10317,37 @@ def test_secure_source_manager_grpc_lro_async_client():
|
|
|
10302
10317
|
assert transport.operations_client is transport.operations_client
|
|
10303
10318
|
|
|
10304
10319
|
|
|
10305
|
-
def
|
|
10320
|
+
def test_ca_pool_path():
|
|
10306
10321
|
project = "squid"
|
|
10307
10322
|
location = "clam"
|
|
10308
|
-
|
|
10309
|
-
|
|
10323
|
+
ca_pool = "whelk"
|
|
10324
|
+
expected = "projects/{project}/locations/{location}/caPools/{ca_pool}".format(
|
|
10325
|
+
project=project,
|
|
10326
|
+
location=location,
|
|
10327
|
+
ca_pool=ca_pool,
|
|
10328
|
+
)
|
|
10329
|
+
actual = SecureSourceManagerClient.ca_pool_path(project, location, ca_pool)
|
|
10330
|
+
assert expected == actual
|
|
10331
|
+
|
|
10332
|
+
|
|
10333
|
+
def test_parse_ca_pool_path():
|
|
10334
|
+
expected = {
|
|
10335
|
+
"project": "octopus",
|
|
10336
|
+
"location": "oyster",
|
|
10337
|
+
"ca_pool": "nudibranch",
|
|
10338
|
+
}
|
|
10339
|
+
path = SecureSourceManagerClient.ca_pool_path(**expected)
|
|
10340
|
+
|
|
10341
|
+
# Check that the path construction is reversible.
|
|
10342
|
+
actual = SecureSourceManagerClient.parse_ca_pool_path(path)
|
|
10343
|
+
assert expected == actual
|
|
10344
|
+
|
|
10345
|
+
|
|
10346
|
+
def test_crypto_key_path():
|
|
10347
|
+
project = "cuttlefish"
|
|
10348
|
+
location = "mussel"
|
|
10349
|
+
key_ring = "winkle"
|
|
10350
|
+
crypto_key = "nautilus"
|
|
10310
10351
|
expected = "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}".format(
|
|
10311
10352
|
project=project,
|
|
10312
10353
|
location=location,
|
|
@@ -10321,10 +10362,10 @@ def test_crypto_key_path():
|
|
|
10321
10362
|
|
|
10322
10363
|
def test_parse_crypto_key_path():
|
|
10323
10364
|
expected = {
|
|
10324
|
-
"project": "
|
|
10325
|
-
"location": "
|
|
10326
|
-
"key_ring": "
|
|
10327
|
-
"crypto_key": "
|
|
10365
|
+
"project": "scallop",
|
|
10366
|
+
"location": "abalone",
|
|
10367
|
+
"key_ring": "squid",
|
|
10368
|
+
"crypto_key": "clam",
|
|
10328
10369
|
}
|
|
10329
10370
|
path = SecureSourceManagerClient.crypto_key_path(**expected)
|
|
10330
10371
|
|
|
@@ -10334,9 +10375,9 @@ def test_parse_crypto_key_path():
|
|
|
10334
10375
|
|
|
10335
10376
|
|
|
10336
10377
|
def test_instance_path():
|
|
10337
|
-
project = "
|
|
10338
|
-
location = "
|
|
10339
|
-
instance = "
|
|
10378
|
+
project = "whelk"
|
|
10379
|
+
location = "octopus"
|
|
10380
|
+
instance = "oyster"
|
|
10340
10381
|
expected = "projects/{project}/locations/{location}/instances/{instance}".format(
|
|
10341
10382
|
project=project,
|
|
10342
10383
|
location=location,
|
|
@@ -10348,9 +10389,9 @@ def test_instance_path():
|
|
|
10348
10389
|
|
|
10349
10390
|
def test_parse_instance_path():
|
|
10350
10391
|
expected = {
|
|
10351
|
-
"project": "
|
|
10352
|
-
"location": "
|
|
10353
|
-
"instance": "
|
|
10392
|
+
"project": "nudibranch",
|
|
10393
|
+
"location": "cuttlefish",
|
|
10394
|
+
"instance": "mussel",
|
|
10354
10395
|
}
|
|
10355
10396
|
path = SecureSourceManagerClient.instance_path(**expected)
|
|
10356
10397
|
|
|
@@ -10360,9 +10401,9 @@ def test_parse_instance_path():
|
|
|
10360
10401
|
|
|
10361
10402
|
|
|
10362
10403
|
def test_repository_path():
|
|
10363
|
-
project = "
|
|
10364
|
-
location = "
|
|
10365
|
-
repository = "
|
|
10404
|
+
project = "winkle"
|
|
10405
|
+
location = "nautilus"
|
|
10406
|
+
repository = "scallop"
|
|
10366
10407
|
expected = (
|
|
10367
10408
|
"projects/{project}/locations/{location}/repositories/{repository}".format(
|
|
10368
10409
|
project=project,
|
|
@@ -10376,9 +10417,9 @@ def test_repository_path():
|
|
|
10376
10417
|
|
|
10377
10418
|
def test_parse_repository_path():
|
|
10378
10419
|
expected = {
|
|
10379
|
-
"project": "
|
|
10380
|
-
"location": "
|
|
10381
|
-
"repository": "
|
|
10420
|
+
"project": "abalone",
|
|
10421
|
+
"location": "squid",
|
|
10422
|
+
"repository": "clam",
|
|
10382
10423
|
}
|
|
10383
10424
|
path = SecureSourceManagerClient.repository_path(**expected)
|
|
10384
10425
|
|
|
@@ -10387,6 +10428,34 @@ def test_parse_repository_path():
|
|
|
10387
10428
|
assert expected == actual
|
|
10388
10429
|
|
|
10389
10430
|
|
|
10431
|
+
def test_service_attachment_path():
|
|
10432
|
+
project = "whelk"
|
|
10433
|
+
region = "octopus"
|
|
10434
|
+
service_attachment = "oyster"
|
|
10435
|
+
expected = "projects/{project}/regions/{region}/serviceAttachments/{service_attachment}".format(
|
|
10436
|
+
project=project,
|
|
10437
|
+
region=region,
|
|
10438
|
+
service_attachment=service_attachment,
|
|
10439
|
+
)
|
|
10440
|
+
actual = SecureSourceManagerClient.service_attachment_path(
|
|
10441
|
+
project, region, service_attachment
|
|
10442
|
+
)
|
|
10443
|
+
assert expected == actual
|
|
10444
|
+
|
|
10445
|
+
|
|
10446
|
+
def test_parse_service_attachment_path():
|
|
10447
|
+
expected = {
|
|
10448
|
+
"project": "nudibranch",
|
|
10449
|
+
"region": "cuttlefish",
|
|
10450
|
+
"service_attachment": "mussel",
|
|
10451
|
+
}
|
|
10452
|
+
path = SecureSourceManagerClient.service_attachment_path(**expected)
|
|
10453
|
+
|
|
10454
|
+
# Check that the path construction is reversible.
|
|
10455
|
+
actual = SecureSourceManagerClient.parse_service_attachment_path(path)
|
|
10456
|
+
assert expected == actual
|
|
10457
|
+
|
|
10458
|
+
|
|
10390
10459
|
def test_common_billing_account_path():
|
|
10391
10460
|
billing_account = "winkle"
|
|
10392
10461
|
expected = "billingAccounts/{billing_account}".format(
|
|
File without changes
|
{google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/MANIFEST.in
RENAMED
|
File without changes
|
{google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/README.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google-cloud-securesourcemanager-0.1.6 → google_cloud_securesourcemanager-0.1.8}/tests/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|